summaryrefslogtreecommitdiff
path: root/Kernel
diff options
context:
space:
mode:
authorAndrew Kaster <andrewdkaster@gmail.com>2021-05-24 05:12:49 -0600
committerAndreas Kling <kling@serenityos.org>2021-05-27 15:18:03 +0200
commita223ef3c4fa01da1deb8a453e3aa9c9021bcc939 (patch)
tree41bd9dffb489e6bbf6ba1d4f93ca5e0c9298d984 /Kernel
parent0e4431af33dfdbac24bf932e7a9137da73174511 (diff)
downloadserenity-a223ef3c4fa01da1deb8a453e3aa9c9021bcc939.zip
Tests: Use ByteBuffer::create_zeroed in TestDeflate instead of memset
The round trip compress test wants the first half of the byte buffer to be filled with random data, and the second half to be all zeroes. The strategy of using memset on ByteBuffer::offset_pointer confuses __builtin_memset_chk when building with -fsanitize=undefined. It thinks that the buffer is using inline capacity when we can prove to ourselves pretty easily that it's not. To avoid this, just create the buffer zeroed to start, and then fill the first half with the random data.
Diffstat (limited to 'Kernel')
0 files changed, 0 insertions, 0 deletions