Skip to content

Commit dddf5c8

Browse files
author
Xu Shaohua
committed
Fixed heic header error
1 parent 68fda3e commit dddf5c8

File tree

2 files changed

+8
-2
lines changed

2 files changed

+8
-2
lines changed

debian/changelog

+6
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,9 @@
1+
qt-heifimageplugin (0.1-2) unstable; urgency=medium
2+
3+
* Fixed header parse error
4+
5+
-- Xu Shaohua <[email protected]> Mon, 04 Jun 2018 20:08:18 +0800
6+
17
qt-heifimageplugin (0.1-1) unstable; urgency=medium
28

39
* Initial release

src/iohandler.cpp

+2-2
Original file line numberDiff line numberDiff line change
@@ -32,8 +32,8 @@ bool IOHandler::canReadFrom(QIODevice& device) {
3232
return false;
3333
}
3434

35-
const QByteArray w1 = header.mid(0, 4);
36-
const QByteArray w2 = header.mid(4, 4);
35+
const QByteArray w1 = header.mid(4, 4);
36+
const QByteArray w2 = header.mid(8, 4);
3737

3838
return w1 == "ftyp" && (w2 == "heic" || w2 == "heix" || w2 == "mifi");
3939
}

0 commit comments

Comments
 (0)