From 6911290dbb577fb295e556da6fd7e4f5f7c81a8a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marc=20Andr=C3=A9=20Tanner?= Date: Mon, 20 Feb 2017 11:37:43 +0100 Subject: test/fuzz: add fuzzing infrastructure For now we use the american fuzzy lop in the future we might also add libFuzzer support. --- fuzz/fuzzer.h | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) create mode 100644 fuzz/fuzzer.h (limited to 'fuzz/fuzzer.h') diff --git a/fuzz/fuzzer.h b/fuzz/fuzzer.h new file mode 100644 index 0000000..3265532 --- /dev/null +++ b/fuzz/fuzzer.h @@ -0,0 +1,18 @@ +#ifndef FUZZER_H +#define FUZZER_H + +enum CmdStatus { + CMD_FAIL = false, + CMD_OK = true, + CMD_ERR, /* syntax error */ + CMD_QUIT, /* quit, accept no further commands */ +}; + +static const char *cmd_status_msg[] = { + [CMD_FAIL] = "Fail\n", + [CMD_OK] = "", + [CMD_ERR] = "Syntax error\n", + [CMD_QUIT] = "Bye\n", +}; + +#endif -- cgit v1.2.3