add basic fuzzers (#348)

* add basic fuzzing using libFuzzer

* let cmake respect cflags, otherwise the fuzzer flags go unnoticed

also, integrates badly with oss-fuzz

* add new fuzzer for minification, simplify the old one

* add fuzzer for the dump example

* clang format
This commit is contained in:
Paul Dreik
2019-10-28 19:46:57 +01:00
committed by Daniel Lemire
parent 15740500af
commit 9442c9e1f4
6 changed files with 134 additions and 2 deletions
+10
View File
@@ -0,0 +1,10 @@
#include "simdjson/jsonparser.h"
#include <cstddef>
#include <cstdint>
#include <string>
extern "C" int LLVMFuzzerTestOneInput(const uint8_t *Data, size_t Size) {
auto ignored = simdjson::build_parsed_json(Data, Size);
return 0;
}