diff options
author | Petteri Aimonen <jpa@git.mail.kapsi.fi> | 2016-12-09 18:57:08 +0200 |
---|---|---|
committer | Petteri Aimonen <jpa@git.mail.kapsi.fi> | 2016-12-09 18:57:08 +0200 |
commit | 58af4d1fb733c5348b68dd3980f2a230d95400b4 (patch) | |
tree | 2d70ebb12e34a4e55fbc369344d98c4e7dc4958f /tests/SConstruct | |
parent | 66a5f06c985537a7e45969c52260b083ec04e82b (diff) |
Enable clang integer sanitizer and clean up a few warnings.
Changed to use simple indexing instead of while (count--) in buf_read()/buf_write(),
because the count overflowed from 0 to max on the last iteration. While the unsigned
integer overflow is defined and behaviour was correct, making this simple change
allowed enabling the sanitizer which might catch true errors elsewhere in the code.
Diffstat (limited to 'tests/SConstruct')
-rw-r--r-- | tests/SConstruct | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/tests/SConstruct b/tests/SConstruct index f2abe042..ae79f710 100644 --- a/tests/SConstruct +++ b/tests/SConstruct @@ -95,7 +95,7 @@ if not env.GetOption('clean'): # Check if we can use undefined behaviour sanitizer (only with clang) # TODO: Fuzz test triggers the bool sanitizer, figure out whether to # modify the fuzz test or to keep ignoring the check. - extra = '-fsanitize=undefined -fno-sanitize-recover=undefined -fsanitize-recover=bool ' + extra = '-fsanitize=undefined,integer -fno-sanitize-recover=undefined,integer -fsanitize-recover=bool ' if 'clang' in env['CC']: if conf.CheckCCFLAGS(extra, linkflags = extra): conf.env.Append(CORECFLAGS = extra) |