mirror of
https://github.com/systemd/systemd.git
synced 2024-12-23 21:35:11 +03:00
sd-rtnl: message - don't put NULL message on rqueue
If nothing interesting was receieved we should not put anything on the queue.
This commit is contained in:
parent
6fc518838c
commit
24a026737d
@ -1194,12 +1194,17 @@ int socket_read_message(sd_rtnl *rtnl) {
|
||||
break;
|
||||
}
|
||||
|
||||
if (first) {
|
||||
r = rtnl_rqueue_make_room(rtnl);
|
||||
if (r < 0)
|
||||
return r;
|
||||
|
||||
rtnl->rqueue[rtnl->rqueue_size ++] = first;
|
||||
first = NULL;
|
||||
}
|
||||
|
||||
if (len)
|
||||
log_debug("sd-rtnl: discarding %zu bytes of incoming message", len);
|
||||
|
||||
return ret;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user