summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGlenn Randers-Pehrson <glennrp at users.sourceforge.net>2017-08-30 06:47:55 -0500
committerGlenn Randers-Pehrson <glennrp at users.sourceforge.net>2017-08-30 06:47:55 -0500
commitefaf42e5df869ae10143184c22c78b3639ac8601 (patch)
tree466c4459828389eec5da0ffb07104dc1a377e03e
parentd3220babe238a1b9c4e95be8a552880d03c6f44c (diff)
downloadlibpng-efaf42e5df869ae10143184c22c78b3639ac8601.tar.gz
[libpng16] Initialize png_handler.row_ptr in
contrib/oss-fuzz/libpng_read_fuzzer.cc
-rw-r--r--contrib/oss-fuzz/libpng_read_fuzzer.cc2
1 files changed, 2 insertions, 0 deletions
diff --git a/contrib/oss-fuzz/libpng_read_fuzzer.cc b/contrib/oss-fuzz/libpng_read_fuzzer.cc
index 1ca3f866f..33bbf97fe 100644
--- a/contrib/oss-fuzz/libpng_read_fuzzer.cc
+++ b/contrib/oss-fuzz/libpng_read_fuzzer.cc
@@ -87,6 +87,8 @@ extern "C" int LLVMFuzzerTestOneInput(const uint8_t* data, size_t size) {
return 0;
}
+ png_handler.row_ptr = nullptr;
+
png_set_crc_action(png_handler.png_ptr, PNG_CRC_QUIET_USE, PNG_CRC_QUIET_USE);
#ifdef PNG_IGNORE_ADLER32
png_set_option(png_handler.png_ptr, PNG_IGNORE_ADLER32, PNG_OPTION_ON);