From fee749f0a1419e300a49ef657106f580c43842c4 Mon Sep 17 00:00:00 2001 From: Nicolas Pena Date: Tue, 28 Nov 2017 15:17:27 +0000 Subject: Fix PDF fuzzers memory limit MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This CL reduces the memory limit in pdf_codec_jbig2_fuzzer. Note that MSAN requires the limit to be lower than the actual bot usage limit. In the testcase, we get OOM just after CFX_DIBitmap::Create. It also increases the limit in xfa_codec_fuzzer.h Bug: 784155 Change-Id: I6fc8d9533ca7dc2b19bf84b9eac23284e05b1e6d Reviewed-on: https://pdfium-review.googlesource.com/19571 Commit-Queue: Nicolás Peña Moreno Reviewed-by: dsinclair --- testing/libfuzzer/xfa_codec_fuzzer.h | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'testing/libfuzzer/xfa_codec_fuzzer.h') diff --git a/testing/libfuzzer/xfa_codec_fuzzer.h b/testing/libfuzzer/xfa_codec_fuzzer.h index c7a16a8005..90706af9f4 100644 --- a/testing/libfuzzer/xfa_codec_fuzzer.h +++ b/testing/libfuzzer/xfa_codec_fuzzer.h @@ -17,9 +17,8 @@ #include "testing/fx_string_testhelpers.h" #include "third_party/base/ptr_util.h" -// Arbitrarily picked to support up to 1000x1000 images. This is far below where -// OOM issues are occuring. -const int kXFACodecFuzzerPixelLimit = 1000000; +// Support up to 512 MB. This prevents trivial OOM when MSAN is on. +const int kXFACodecFuzzerPixelLimit = 512000000; class XFACodecFuzzer { public: -- cgit v1.2.3