diff --git a/contrib/oss-fuzz/README.txt b/contrib/oss-fuzz/README.txt index cb7fb13ff..7e1c4c8a5 100644 --- a/contrib/oss-fuzz/README.txt +++ b/contrib/oss-fuzz/README.txt @@ -13,7 +13,7 @@ They were licensed by Google Inc, using the BSD-like Chromium license, which may be found at https://cs.chromium.org/chromium/src/LICENSE, or, if noted in the source, under the Apache-2.0 license, which may be found at http://www.apache.org/licenses/LICENSE-2.0 . -If they have been modified, the derivatives are copyright Glenn Randers-Pehson +If they have been modified, the derivatives are copyright Glenn Randers-Pehrson and are released under the same licenses as the originals. Several of the original files (libpng_read_fuzzer.options, png.dict, project.yaml) had no licensing information; we assumed that these were under the Chromium diff --git a/contrib/oss-fuzz/libpng_read_fuzzer.cc b/contrib/oss-fuzz/libpng_read_fuzzer.cc index 072219b5f..0fc9e206c 100644 --- a/contrib/oss-fuzz/libpng_read_fuzzer.cc +++ b/contrib/oss-fuzz/libpng_read_fuzzer.cc @@ -5,7 +5,7 @@ // Use of this source code is governed by a BSD-style license that may // be found in the LICENSE file https://cs.chromium.org/chromium/src/LICENSE -// Last changed in libpng 1.6.33beta03 [September 25, 2017] +// Last changed in libpng 1.6.33beta03 [September 27, 2017] // The modifications in 2017 by Glenn Randers-Pehrson include // 1. addition of a PNG_CLEANUP macro, @@ -118,6 +118,9 @@ extern "C" int LLVMFuzzerTestOneInput(const uint8_t* data, size_t size) { return 0; } + /* Treat benign errors as warnings */ + png_set_benign_errors(png_handler.png_ptr, 1); + png_set_crc_action(png_handler.png_ptr, PNG_CRC_QUIET_USE, PNG_CRC_QUIET_USE); #ifdef PNG_IGNORE_ADLER32