Details
-
Task
-
Resolution: Done
-
P2: Important
-
None
-
None
-
3
-
2fd990b386 (qt/qtbase/dev) 2fd990b386 (qt/tqtc-qtbase/dev) 93aa02e671 (qt/qtbase/6.4) 93aa02e671 (qt/tqtc-qtbase/6.4) 2a4d5b41cb (qt/tqtc-qtbase/6.2) 93aa02e671 (qt/tqtc-qtbase/6.4.1) 93aa02e671 (qt/tqtc-qtbase/tqtc/qtinsight-6.4)
-
Foundation Sprint 61, Foundation Sprint 62, Foundation Sprint 63, Foundation Sprint 64, Foundation Sprint 65, Foundation Sprint 66, Foundation Sprint 67, Foundation Sprint 68
Description
The code fails on 64-bit platforms:
const QByteArray ba = ~~~ more than 4GiB of data ~~~; const QByteArray compressed = qCompress(ba); const QByteArray uncompressed = qUncompress(compressed); Q_COMPARE(ba, uncompressed);
It seems to be caused by qCompress() using only four digits to encode the length.
There doesn't appear to be something you can do, unless you change the format to include a longer length indicator.
Attachments
Issue Links
- resulted from
-
QTBUG-103531 Finish migration to qsizetype [qtbase/src/corelib/text]
- Closed
- resulted in
-
QTBUG-106542 qCompress()/qUncompress() cannot handle more than 4GiB of data on Win64
- Closed
-
QTBUG-106543 Develop a method to encode more than UINT_MAX in qCompress() length field
- Open
-
QTBUG-107698 Improve output buffer estimation in qCompress()
- Open