Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/xiph/speex.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'contrib/oss-fuzz/speexdec_fuzzer.cc')
-rw-r--r--contrib/oss-fuzz/speexdec_fuzzer.cc4
1 files changed, 4 insertions, 0 deletions
diff --git a/contrib/oss-fuzz/speexdec_fuzzer.cc b/contrib/oss-fuzz/speexdec_fuzzer.cc
index 7175fa3..e68201d 100644
--- a/contrib/oss-fuzz/speexdec_fuzzer.cc
+++ b/contrib/oss-fuzz/speexdec_fuzzer.cc
@@ -191,6 +191,10 @@ extern "C" int LLVMFuzzerTestOneInput(const uint8_t *fuzz_data, size_t fuzz_size
enh_enabled = 1;
+ /*Check fuzz_data meets size requirements*/
+ if (fuzz_size > 4096)
+ return 0;
+
/*Init Ogg data struct*/
ogg_sync_init(&oy);