mirror of
https://github.com/systemd/systemd-stable.git
synced 2025-01-25 06:03:40 +03:00
If the notification message length is 0, ignore the message (#4237)
Fixes #4234. Signed-off-by: Jorge Niedbalski <jnr@metaklass.org>
This commit is contained in:
parent
831d3dc8d7
commit
531ac2b234
@ -1721,6 +1721,10 @@ static int manager_dispatch_notify_fd(sd_event_source *source, int fd, uint32_t
|
||||
|
||||
return -errno;
|
||||
}
|
||||
if (n == 0) {
|
||||
log_debug("Got zero-length notification message. Ignoring.");
|
||||
return 0;
|
||||
}
|
||||
|
||||
CMSG_FOREACH(cmsg, &msghdr) {
|
||||
if (cmsg->cmsg_level == SOL_SOCKET && cmsg->cmsg_type == SCM_RIGHTS) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user