bus-message: fix calculation of offsets table for arrays
authorZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>
Fri, 3 Aug 2018 12:46:57 +0000 (14:46 +0200)
committerZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>
Tue, 2 Oct 2018 09:53:20 +0000 (11:53 +0200)
commitf88214cf9d66c93f4d22c4c8980de9ee3ff45bab
tree144bec40870c7e911524371236f98e6559b4c377
parent4d82a8d5052fce8c1ea51f8bdec3476fb8cc4747
bus-message: fix calculation of offsets table for arrays

This is similar to the grandparent commit 'fix calculation of offsets table',
except that now the change is for array elements. Same story as before: we need
to make sure that the offsets increase enough taking alignment into account.

While at it, rename 'p' to 'previous' to match similar code in other places.
src/libsystemd/sd-bus/bus-message.c
test/fuzz/fuzz-bus-message/crash-d8f3941c74219b4c03532c9b244d5ea539c61af5 [new file with mode: 0644]