Skip to content

Commit

Permalink
opj_decompress_fuzzer: remove checks regarding input dimensions (fixe…
Browse files Browse the repository at this point in the history
…s #1079)
  • Loading branch information
rouault committed Jun 15, 2019
1 parent f4d6578 commit 8db9d25
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions tests/fuzzers/opj_decompress_fuzzer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -153,6 +153,7 @@ int LLVMFuzzerTestOneInput(const uint8_t *buf, size_t len)
OPJ_UINT32 width = psImage->x1 - psImage->x0;
OPJ_UINT32 height = psImage->y1 - psImage->y0;

#if 0
// Reject too big images since that will require allocating a lot of
// memory
if (width != 0 && psImage->numcomps != 0 &&
Expand Down Expand Up @@ -180,6 +181,7 @@ int LLVMFuzzerTestOneInput(const uint8_t *buf, size_t len)

return 0;
}
#endif

OPJ_UINT32 width_to_read = width;
if (width_to_read > 1024) {
Expand Down

0 comments on commit 8db9d25

Please sign in to comment.