diff options
author | Martin Pitt <martin.pitt@ubuntu.com> | 2016-04-12 18:20:13 +0200 |
---|---|---|
committer | Martin Pitt <martin.pitt@ubuntu.com> | 2016-04-12 18:20:13 +0200 |
commit | 025ef1d2264b24e77283d312dede8af01fa050f6 (patch) | |
tree | 3dd77d23d19943926f36cb60b1685a4fb657bc89 /src/libsystemd/sd-event/sd-event.c | |
parent | 1116e14c49ac1291eb5e46fcf5e691ef57267b54 (diff) | |
parent | 3c6d8e57e870ed56dbb53ce62f0a3d32de101cd8 (diff) |
Merge pull request #2973 from poettering/search-path
Many fixes, in particular to the install logic
Diffstat (limited to 'src/libsystemd/sd-event/sd-event.c')
-rw-r--r-- | src/libsystemd/sd-event/sd-event.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/src/libsystemd/sd-event/sd-event.c b/src/libsystemd/sd-event/sd-event.c index 841358ed03..9fd744768d 100644 --- a/src/libsystemd/sd-event/sd-event.c +++ b/src/libsystemd/sd-event/sd-event.c @@ -1145,8 +1145,7 @@ _public_ int sd_event_add_signal( int r; assert_return(e, -EINVAL); - assert_return(sig > 0, -EINVAL); - assert_return(sig < _NSIG, -EINVAL); + assert_return(SIGNAL_VALID(sig), -EINVAL); assert_return(e->state != SD_EVENT_FINISHED, -ESTALE); assert_return(!event_pid_changed(e), -ECHILD); @@ -2200,7 +2199,7 @@ static int process_signal(sd_event *e, struct signal_data *d, uint32_t events) { if (_unlikely_(n != sizeof(si))) return -EIO; - assert(si.ssi_signo < _NSIG); + assert(SIGNAL_VALID(si.ssi_signo)); read_one = true; |