[PATCH] D26574: [asan] Fix strncmp and strncasecmp interceptors

Vitaly Buka via llvm-commits llvm-commits at lists.llvm.org
Fri Nov 11 20:35:41 PST 2016


vitalybuka created this revision.
vitalybuka added reviewers: kcc, eugenis.
vitalybuka added a subscriber: llvm-commits.
Herald added a subscriber: kubabrecka.

In non-strict mode we will check memory access for both strings from beginning
to either:

1. 0-char
2. size
3. different chars

In strict mode we will check from beginning to either:

1. 0-char
2. size

Previously in strict mode we always checked up to the 0-char.


https://reviews.llvm.org/D26574

Files:
  lib/sanitizer_common/sanitizer_common_interceptors.inc
  test/asan/TestCases/strncmp_strict.c

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D26574.77707.patch
Type: text/x-patch
Size: 5964 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20161112/6f7e6068/attachment.bin>


More information about the llvm-commits mailing list