summaryrefslogtreecommitdiffstats
path: root/src/ctx.h
diff options
context:
space:
mode:
authorTavian Barnes <tavianator@tavianator.com>2023-11-06 10:06:41 -0500
committerTavian Barnes <tavianator@tavianator.com>2023-11-06 10:10:08 -0500
commitad1b36291fe87ca9d647980e3afdc71344d66519 (patch)
treeddbbc5eabf62ff2e2e3266ea6fdcd7e7f37d9a18 /src/ctx.h
parent816574513e0e163aff9f183721697f157eb158fa (diff)
downloadbfs-ad1b36291fe87ca9d647980e3afdc71344d66519.tar.xz
ctx: Store the original and current RLIMIT_NOFILE
Diffstat (limited to 'src/ctx.h')
-rw-r--r--src/ctx.h8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/ctx.h b/src/ctx.h
index 96406bd..1c7df63 100644
--- a/src/ctx.h
+++ b/src/ctx.h
@@ -87,10 +87,10 @@ struct bfs_ctx {
/** The number of files owned by the context. */
int nfiles;
- /** The initial RLIMIT_NOFILE soft limit. */
- rlim_t nofile_soft;
- /** The initial RLIMIT_NOFILE hard limit. */
- rlim_t nofile_hard;
+ /** The initial RLIMIT_NOFILE limits. */
+ struct rlimit orig_nofile;
+ /** The current RLIMIT_NOFILE limits. */
+ struct rlimit cur_nofile;
/** The current time. */
struct timespec now;