qtimageformats/tests
Eirik Aavitsland b2405d3411 Fix macjp2 canRead() function
The canRead() function is supposed to check for the presence of a 12
byte magic number (header). It used qstrncmp() for this, but as the
byte sequence starts with 0 values, the comparison would end after the
first byte, and any data also starting with a 0 value would be taken
as matching.

This would make QImageReader mis-identify the image format of image
data where an explicit suffix or data format was lacking, resulting in
image reading failures. The macheif autotest would hit this issue and
fail erroneously.

Pick-to: 6.7 6.5
Change-Id: I39b1ba9a344478fe1255c89f19488f0bc54d2ec1
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
(cherry picked from commit 7ab8952608)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
2024-06-03 14:32:22 +00:00
..
auto Fix macjp2 canRead() function 2024-06-03 14:32:22 +00:00
benchmarks Correct license for test files 2024-03-15 15:10:22 +01:00
shared/images TIFF: add an autotest for CMYK images 2024-04-08 08:36:57 +02:00
CMakeLists.txt Remove remains of qmake conversion from CMakeLists.txt files 2023-02-08 16:20:50 +01:00