diff options
author | Egor Tensin <Egor.Tensin@gmail.com> | 2023-06-13 05:08:30 +0200 |
---|---|---|
committer | Egor Tensin <Egor.Tensin@gmail.com> | 2023-06-14 06:23:37 +0200 |
commit | 27fd6f9615f36aec71877e2b99aa3655e22da75d (patch) | |
tree | 61fad1a87ed71a594a12682e2bf50801c27c8460 /src/signal.c | |
parent | cmake: fix grammar in option description (diff) | |
download | cimple-27fd6f9615f36aec71877e2b99aa3655e22da75d.tar.gz cimple-27fd6f9615f36aec71877e2b99aa3655e22da75d.zip |
minor refactoring
Diffstat (limited to 'src/signal.c')
-rw-r--r-- | src/signal.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/signal.c b/src/signal.c index 15d90ab..cbe4aed 100644 --- a/src/signal.c +++ b/src/signal.c @@ -57,6 +57,7 @@ int signal_block_sigterms(void) int signalfd_create(const sigset_t *set) { + static const int flags = SFD_CLOEXEC; sigset_t old; int ret = 0; @@ -64,7 +65,7 @@ int signalfd_create(const sigset_t *set) if (ret < 0) return ret; - ret = signalfd(-1, set, SFD_CLOEXEC); + ret = signalfd(-1, set, flags); if (ret < 0) goto restore; |