]> Savannah Git Hosting - gnulib.git/commit
alignalloc: work around AddressSanitizer bug
authorPaul Eggert <eggert@cs.ucla.edu>
Thu, 27 Jan 2022 19:36:00 +0000 (11:36 -0800)
committerPaul Eggert <eggert@cs.ucla.edu>
Thu, 27 Jan 2022 19:38:02 +0000 (11:38 -0800)
commit69822de4243b40e1da10046e1c12e79703ea9a7d
tree2601e903bafa9e2f3b46d918fad299bb13d87d49
parentf693539b7719ac1bd8655a5c8800c5112515f147
alignalloc: work around AddressSanitizer bug

* doc/posix-functions/aligned_alloc.texi (aligned_alloc):
Mention AddressSanitizer bug.
* lib/alignalloc.h (ALIGNALLOC_VIA_ALIGNED_ALLOC):
Define to 0 if AddressSanitizer is in use.
* tests/test-alignalloc.c (test_alignalloc): New function,
which tests for non-aligned sizes too.
(main): Use it.  Don’t bother checking for alignments
greater than 16 MiB, as this flummoxes AddressSanitizer
and there seems little point to testing them.
ChangeLog
doc/posix-functions/aligned_alloc.texi
lib/alignalloc.h
tests/test-alignalloc.c