diff options
Diffstat (limited to 'pkg/csource')
| -rw-r--r-- | pkg/csource/generated.go | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/pkg/csource/generated.go b/pkg/csource/generated.go index 7c01243ce..2c33e7a29 100644 --- a/pkg/csource/generated.go +++ b/pkg/csource/generated.go @@ -12330,6 +12330,25 @@ static int do_sandbox_none(void) } #endif +#if SYZ_EXECUTOR || __NR_syz_test_fuzzer1 + +static void fake_crash(const char* name) +{ + failmsg("crash", "{{CRASH: %s}}", name); + doexit(1); +} + +static long syz_test_fuzzer1(volatile long a, volatile long b, volatile long c) +{ + if (a == 1 && b == 1 && c == 1) + fake_crash("first bug"); + if (a == 1 && b == 2 && c == 3) + fake_crash("second bug"); + return 0; +} + +#endif + #elif GOOS_windows #include <direct.h> |
