Closed
Bug 1723082
Opened 4 years ago
Closed 3 years ago
IOUtils.read throws Uncaught DOMException error for large file
Categories
(Toolkit Graveyard :: OS.File, defect, P3)
Toolkit Graveyard
OS.File
Tracking
(firefox96 fixed)
RESOLVED
FIXED
96 Branch
Tracking | Status | |
---|---|---|
firefox96 | --- | fixed |
People
(Reporter: rnons, Assigned: beth)
References
Details
Attachments
(1 file)
Test code
await IOUtils.read('a_3.9GB_file')
Error
Uncaught (in promise) DOMException: Encountered an unexpected error while reading file(...path...)
It's better to document the max file size supported, and throw a more specific error like NS_ERROR_FILE_TOO_BIG.
Assignee | ||
Updated•3 years ago
|
Assignee: nobody → brennie
Severity: -- → S3
Priority: -- → P3
Assignee | ||
Comment 1•3 years ago
|
||
Previously, if you attempted to read a file greater than INT32_MAX in size, we
would either fail to read the file (on release) or crash (on debug). This is
due to the implementation of _PR_MD_READ accepting an int32_t of bytes to read
instead of a uint32_t, which nsFileStream::Read accepts and passes on.
Depends on D131160
Pushed by brennie@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/492f5ca3b592
Support reading files > INT32_MAX in IOUtils r=Gijs
Comment 3•3 years ago
|
||
Backed out 3 changesets (Bug 1741247, Bug 1723082, Bug 1736175) for causing PathUtils.normalize failures.
Backout link: https://hg.mozilla.org/integration/autoland/rev/72c397486d4cec809c954f4be3df881c2db93d56
Push with failures, failure log.
Pushed by brennie@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/688444ccc86a
Support reading files > INT32_MAX in IOUtils r=Gijs
Comment 5•3 years ago
|
||
bugherder |
Status: NEW → RESOLVED
Closed: 3 years ago
status-firefox96:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → 96 Branch
Updated•2 years ago
|
Product: Toolkit → Toolkit Graveyard
You need to log in
before you can comment on or make changes to this bug.
Description
•