We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 42216df commit 832ae16Copy full SHA for 832ae16
1 file changed
fuzz_test/fuzz_tester.cpp
@@ -1,14 +1,16 @@
1
-#include <stdint.h>
2
-#include <stddef.h>
+#include <cstdint>
+#include <cstddef>
3
4
-
5
-// example comes from here: https://github.com/google/fuzzing/blob/master/tutorial/libFuzzer/fuzz_me.cc
6
-// Documentation can be found here: https://llvm.org/docs/LibFuzzer.html
+/*
+ * example comes from here: https://github.com/google/fuzzing/blob/master/tutorial/libFuzzer/fuzz_me.cc
+ * Documentation can be found here: https://llvm.org/docs/LibFuzzer.html
7
+ */
8
bool FuzzMe(const uint8_t *Data, size_t DataSize) {
9
return DataSize >= 3 &&
10
Data[0] == 'F' &&
11
Data[1] == 'U' &&
12
Data[2] == 'Z' &&
13
+ // the following is on purpose to demonstrate an error
14
Data[3] == 'Z'; // :‑<
15
}
16
0 commit comments