1
0
mirror of https://github.com/systemd/systemd.git synced 2024-12-25 01:34:28 +03:00

bus-message: output debug information about offset troubles

This commit is contained in:
Zbigniew Jędrzejewski-Szmek 2018-08-03 18:05:27 +02:00
parent 10a7ec96d8
commit 0b4775b527

View File

@ -3820,8 +3820,11 @@ static int build_struct_offsets(
x = size - (n_variable * sz);
offset = m->rindex + x;
if (offset < start)
if (offset < start) {
log_debug("For type %s with alignment %zu, message specifies offset %zu which is smaller than previous end %zu + alignment = %zu",
t, align, offset, previous, start);
return -EBADMSG;
}
} else
/* Fixed size */
offset = start + k;