From 86d8c8e9e6614b30095d5d0b783f1ed2b145b1fa Mon Sep 17 00:00:00 2001 From: Claude Date: Tue, 27 Oct 2026 09:36:06 +0000 Subject: [PATCH] fuzz/c/std: cap the brotli fuzzer's encoder input lengths Large inputs at qualities 10 and 11 made some fuzz inputs take tens of seconds under sanitizers. --- fuzz/c/std/brotli_fuzzer.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/fuzz/c/std/brotli_fuzzer.c b/fuzz/c/std/brotli_fuzzer.c index 2fa7228e..f92f764b 100644 --- a/fuzz/c/std/brotli_fuzzer.c +++ b/fuzz/c/std/brotli_fuzzer.c @@ -129,8 +129,8 @@ static const uint8_t g_serialized_dictionary[] = { // The encoder's input is capped (a prefix of the fuzz input), as is the input // at qualities 10 and 11, which are slow. -#define ENC_MAX_INPUT 262144 -#define ENC_MAX_INPUT_HQ 32768 +#define ENC_MAX_INPUT 65536 +#define ENC_MAX_INPUT_HQ 4096 #define ENC_DST_ARRAY_SIZE (2 * ENC_MAX_INPUT + 65536) static wuffs_brotli__encoder g_encoder;