mirror of
https://github.com/clearlinux/systemd-stable.git
synced 2026-10-03 23:38:39 +00:00
bus: properly handle empty messages
This commit is contained in:
@@ -3061,7 +3061,7 @@ static int message_peek_body(
|
||||
}
|
||||
|
||||
part = find_part(m, start, nbytes, (void**) &q);
|
||||
if (!part || !q)
|
||||
if (!part || (nbytes > 0 && !q))
|
||||
return -EBADMSG;
|
||||
|
||||
*rindex = end;
|
||||
|
||||
Reference in New Issue
Block a user