Details
-
Bug
-
Resolution: Done
-
P2: Important
-
None
-
6.5.2
-
None
Description
I'm using file I/O in a WASM environment and encounter that QByteArray reserves too much memory. This results in not being able to use QByteArrays which are bigger than 550MB as this will reserve a >2GB section of memory internally.
Example:
Opening a file of 512MB with QFileDialog::getOpenFileContent works, but allocates around 1GB of memory (which can be reduced with squeeze()-ing of course).
Opening a file of 550MB with QFileDialog::getOpenFileContent causes a crash.
File handling is now limited to the unintended (and excessive) allocation of the QByteArray...