diff options
author | Viktor Engelmann <viktor.engelmann@qt.io> | 2017-08-18 14:50:20 +0200 |
---|---|---|
committer | Allan Sandfeld Jensen <allan.jensen@qt.io> | 2018-05-23 13:31:33 +0200 |
commit | 79e27ed094ad9466b78e441b467ca513d6919021 (patch) | |
tree | 5d4b32584ba838e4afac9b335114367da9497abf | |
parent | 7a5edacc46451ac29af6557975f1638725b21274 (diff) | |
download | qtwebengine-chromium-79e27ed094ad9466b78e441b467ca513d6919021.tar.gz |
Fix improper boolean values
jpeg_codec.cc contained some implicit conversions to boolean, which
is apparently problematic for some versions of libjpeg. Patch
taken from https://bugs.chromium.org/p/chromium/issues/detail?id=686191
but not backported, since it has not been accepted into chromium yet.
Task-Number: QTBUG-58482
Change-Id: I2c5d5894493d6a7d0698a4e5a7191288a2fdfeb4
Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
-rw-r--r-- | chromium/ui/gfx/codec/jpeg_codec.cc | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/chromium/ui/gfx/codec/jpeg_codec.cc b/chromium/ui/gfx/codec/jpeg_codec.cc index 5ff77d782b8..dff1726d81f 100644 --- a/chromium/ui/gfx/codec/jpeg_codec.cc +++ b/chromium/ui/gfx/codec/jpeg_codec.cc @@ -108,7 +108,7 @@ void InitSource(j_decompress_ptr cinfo) { // set to a positive value if TRUE is returned. A FALSE return should only // be used when I/O suspension is desired." boolean FillInputBuffer(j_decompress_ptr cinfo) { - return false; + return FALSE; } // Skip data in the buffer. Since we have all the data at once, this operation @@ -211,7 +211,7 @@ bool JPEGCodec::Decode(const unsigned char* input, size_t input_size, cinfo.client_data = &state; // fill the file metadata into our buffer - if (jpeg_read_header(&cinfo, true) != JPEG_HEADER_OK) + if (jpeg_read_header(&cinfo, TRUE) != JPEG_HEADER_OK) return false; // we want to always get RGB data out |