summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Fuzzer/test/overwrite-input.test
diff options
context:
space:
mode:
authorKostya Serebryany <kcc@google.com>2017-05-09 01:17:29 +0000
committerKostya Serebryany <kcc@google.com>2017-05-09 01:17:29 +0000
commitfe4ed9bd854d1230723568a8cc6289bf9da7fff7 (patch)
treec9d6415d69ed700008c4c4783eb3cb80048411f4 /llvm/lib/Fuzzer/test/overwrite-input.test
parent9f29914d4018c0c8ef2b7b7bceffb0d07483e89c (diff)
downloadbcm5719-llvm-fe4ed9bd854d1230723568a8cc6289bf9da7fff7.tar.gz
bcm5719-llvm-fe4ed9bd854d1230723568a8cc6289bf9da7fff7.zip
[libFuzzer] make sure the input data is not overwritten in the fuzz target (if it is -- report an error)
llvm-svn: 302494
Diffstat (limited to 'llvm/lib/Fuzzer/test/overwrite-input.test')
-rw-r--r--llvm/lib/Fuzzer/test/overwrite-input.test2
1 files changed, 2 insertions, 0 deletions
diff --git a/llvm/lib/Fuzzer/test/overwrite-input.test b/llvm/lib/Fuzzer/test/overwrite-input.test
new file mode 100644
index 00000000000..81c27909e8d
--- /dev/null
+++ b/llvm/lib/Fuzzer/test/overwrite-input.test
@@ -0,0 +1,2 @@
+RUN: not LLVMFuzzer-OverwriteInputTest 2>&1 | FileCheck %s
+CHECK: ERROR: libFuzzer: fuzz target overwrites it's const input
OpenPOWER on IntegriCloud