Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1963)

Unified Diff: third_party/afl/src/libdislocator/libdislocator.so.c

Issue 2662883002: Roll AFL 2.31b:2.38b and switch coverage to use trace-pc-guard. (Closed)
Patch Set: Remove unneeded vuln_samples binaries. Created 3 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/afl/src/libdislocator/libdislocator.so.c
diff --git a/third_party/afl/src/libdislocator/libdislocator.so.c b/third_party/afl/src/libdislocator/libdislocator.so.c
index 1d4648f3ce8ad8b258c7f46e4c8c1413e69347b5..0dfc98e6058a4ab0cb8f5507a82ec05537c598f8 100644
--- a/third_party/afl/src/libdislocator/libdislocator.so.c
+++ b/third_party/afl/src/libdislocator/libdislocator.so.c
@@ -64,7 +64,7 @@
/* Canary & clobber bytes: */
#define ALLOC_CANARY 0xAACCAACC
-#define ALLOC_CLOBBER 0x41
+#define ALLOC_CLOBBER 0xCC
#define PTR_C(_p) (((u32*)(_p))[-1])
#define PTR_L(_p) (((u32*)(_p))[-2])
@@ -89,7 +89,8 @@ static void* __dislocator_alloc(size_t len) {
void* ret;
- if (total_mem + len > max_mem) {
+
+ if (total_mem + len > max_mem || total_mem + len < total_mem) {
if (hard_fail)
FATAL("total allocs exceed %u MB", max_mem / 1024 / 1024);
« no previous file with comments | « third_party/afl/src/docs/vuln_samples/unzip-t-mem-corruption.zip ('k') | third_party/afl/src/llvm_mode/README.llvm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698