summaryrefslogtreecommitdiffstats
path: root/tests/auto/gui/image/qimage/tst_qimage.cpp
diff options
context:
space:
mode:
authorRainer Keller <rainer.keller@theqtcompany.com>2015-06-29 10:16:36 +0200
committerAllan Sandfeld Jensen <allan.jensen@theqtcompany.com>2015-07-17 11:37:02 +0000
commit954f0d93976362d29044439e4eaa11d2dff16624 (patch)
treee3263aa6170206d2fabfc64c6d8d9c8fd5a8ebdd /tests/auto/gui/image/qimage/tst_qimage.cpp
parent756266d01560157b7274e466b9ffc1b0e2ef9a1f (diff)
Add test for invalid exif data
Task-number: QTBUG-46870 Change-Id: Idfde92ca12336c6432798b4517e244c2f5a5ba4d Reviewed-by: Allan Sandfeld Jensen <allan.jensen@theqtcompany.com>
Diffstat (limited to 'tests/auto/gui/image/qimage/tst_qimage.cpp')
-rw-r--r--tests/auto/gui/image/qimage/tst_qimage.cpp8
1 files changed, 8 insertions, 0 deletions
diff --git a/tests/auto/gui/image/qimage/tst_qimage.cpp b/tests/auto/gui/image/qimage/tst_qimage.cpp
index f7c71f05bd..8286c800c2 100644
--- a/tests/auto/gui/image/qimage/tst_qimage.cpp
+++ b/tests/auto/gui/image/qimage/tst_qimage.cpp
@@ -185,6 +185,7 @@ private slots:
void exifOrientation();
void exif_QTBUG45865();
+ void exif_invalid_data_QTBUG46870();
void cleanupFunctions();
@@ -2872,6 +2873,13 @@ void tst_QImage::exif_QTBUG45865()
QCOMPARE(image.size(), QSize(5, 8));
}
+void tst_QImage::exif_invalid_data_QTBUG46870()
+{
+ QImage image;
+ QVERIFY(image.load(m_prefix + "jpeg_exif_invalid_data_QTBUG-46870.jpg"));
+ QVERIFY(!image.isNull());
+}
+
static void cleanupFunction(void* info)
{
bool *called = static_cast<bool*>(info);