diff options
author | thestig <thestig@chromium.org> | 2016-09-26 16:14:28 -0700 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2016-09-26 16:14:28 -0700 |
commit | 2ab466e3a59d845422e06e50bc38d4bf31ac1adf (patch) | |
tree | f34d7121c70042306739281445f2c19e83185fed /testing/libfuzzer/pdf_codec_fax_fuzzer.cc | |
parent | 2c065322f1b14ca3ff145dc068ab2361704f9e4b (diff) | |
download | pdfium-2ab466e3a59d845422e06e50bc38d4bf31ac1adf.tar.xz |
Clean up fx_codec_fax.cpp.
Review-Url: https://codereview.chromium.org/2357173005
Diffstat (limited to 'testing/libfuzzer/pdf_codec_fax_fuzzer.cc')
-rw-r--r-- | testing/libfuzzer/pdf_codec_fax_fuzzer.cc | 13 |
1 files changed, 6 insertions, 7 deletions
diff --git a/testing/libfuzzer/pdf_codec_fax_fuzzer.cc b/testing/libfuzzer/pdf_codec_fax_fuzzer.cc index 60e2c9ff19..f6cc1e7200 100644 --- a/testing/libfuzzer/pdf_codec_fax_fuzzer.cc +++ b/testing/libfuzzer/pdf_codec_fax_fuzzer.cc @@ -22,17 +22,16 @@ extern "C" int LLVMFuzzerTestOneInput(const uint8_t* data, size_t size) { int K = GetInteger(data + 8); int Columns = GetInteger(data + 12); int Rows = GetInteger(data + 16); - FX_BOOL EndOfLine = (data[20] & 0x01) == 0; - FX_BOOL ByteAlign = (data[20] & 0x02) == 0; - FX_BOOL BlackIs1 = (data[20] & 0x04) == 0; + bool EndOfLine = !(data[20] & 0x01); + bool ByteAlign = !(data[20] & 0x02); + bool BlackIs1 = !(data[20] & 0x04); data += kParameterSize; size -= kParameterSize; CCodec_FaxModule fax_module; - std::unique_ptr<CCodec_ScanlineDecoder> decoder; - decoder.reset(fax_module.CreateDecoder(data, size, width, height, K, - EndOfLine, ByteAlign, BlackIs1, - Columns, Rows)); + std::unique_ptr<CCodec_ScanlineDecoder> decoder( + fax_module.CreateDecoder(data, size, width, height, K, EndOfLine, + ByteAlign, BlackIs1, Columns, Rows)); if (decoder) { int line = 0; |