[PATCH] D27731: [libFuzzer] Diff 22 - Fix index error in SearchMemory() implementation for Windows.
Marcos Pividori via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri Dec 16 09:45:51 PST 2016
This revision was automatically updated to reflect the committed changes.
Closed by commit rL289966: [libFuzzer] Fix index error in SearchMemory() implementation for Windows. (authored by mpividori).
Changed prior to commit:
https://reviews.llvm.org/D27731?vs=81298&id=81770#toc
Repository:
rL LLVM
https://reviews.llvm.org/D27731
Files:
llvm/trunk/lib/Fuzzer/FuzzerUtilWindows.cpp
Index: llvm/trunk/lib/Fuzzer/FuzzerUtilWindows.cpp
===================================================================
--- llvm/trunk/lib/Fuzzer/FuzzerUtilWindows.cpp
+++ llvm/trunk/lib/Fuzzer/FuzzerUtilWindows.cpp
@@ -168,7 +168,7 @@
if (PattLen == 1)
return memchr(Data, *Cpatt, DataLen);
- const char *End = Cdata + DataLen - PattLen;
+ const char *End = Cdata + DataLen - PattLen + 1;
for (const char *It = Cdata; It < End; ++It)
if (It[0] == Cpatt[0] && memcmp(It, Cpatt, PattLen) == 0)
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D27731.81770.patch
Type: text/x-patch
Size: 514 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20161216/c9882b26/attachment.bin>
More information about the llvm-commits
mailing list