summaryrefslogtreecommitdiff
path: root/test/fuzz
diff options
context:
space:
mode:
authorZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>2018-07-09 07:03:01 +0200
committerZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>2018-10-02 11:42:45 +0200
commit7f546026abbdc56c453a577e52d57159458c3e9c (patch)
tree47fa1d225508c78446a7651061c86dc992f66551 /test/fuzz
parent56b560c26339c4b282c06038316a91509eae75fd (diff)
downloadsystemd-7f546026abbdc56c453a577e52d57159458c3e9c.tar.gz
systemd-7f546026abbdc56c453a577e52d57159458c3e9c.tar.bz2
systemd-7f546026abbdc56c453a577e52d57159458c3e9c.zip
Introduce free_and_strndup and use it in bus-message.c
v2: fix error in free_and_strndup() When the orignal and copied message were the same, but shorter than specified length l, memory read past the end of the buffer would be performed. A test case is included: a string that had an embedded NUL ("q\0") is used to replace "q". v3: Fix one more bug in free_and_strndup and add tests. v4: Some style fixed based on review, one more use of free_and_replace, and make the tests more comprehensive.
Diffstat (limited to 'test/fuzz')
-rw-r--r--test/fuzz/fuzz-bus-message/crash-b88ad9ecf4aacf4a0caca5b5543953265367f084bin0 -> 32 bytes
1 files changed, 0 insertions, 0 deletions
diff --git a/test/fuzz/fuzz-bus-message/crash-b88ad9ecf4aacf4a0caca5b5543953265367f084 b/test/fuzz/fuzz-bus-message/crash-b88ad9ecf4aacf4a0caca5b5543953265367f084
new file mode 100644
index 0000000000..52469650b5
--- /dev/null
+++ b/test/fuzz/fuzz-bus-message/crash-b88ad9ecf4aacf4a0caca5b5543953265367f084
Binary files differ