[Downloads API] A file with a size >1GB is not displayed successfully

VERIFIED FIXED in Firefox OS v1.4

Status

Firefox OS
General
VERIFIED FIXED
4 years ago
4 years ago

People

(Reporter: rafael.marquez, Assigned: tedders1)

Tracking

unspecified
1.4 S2 (28feb)
Other
Gonk (Firefox OS)

Firefox Tracking Flags

(blocking-b2g:1.4+, b2g-v1.4 verified)

Details

(Whiteboard: [systemsfe][p=1])

Attachments

(3 attachments)

(Reporter)

Description

4 years ago
Created attachment 8373370 [details]
GB file.png

*Procedure
1. Open https://owd.tid.es/dm/
2. Download a file 1GB "ocupamucho.tgz"
3. Open download list during the download

*Expected Result
The file is displayed successfull. File size is displayed as GB

*Actual Result
The file is not displayed successfull. File size is displayed as B.  See the attached file
(Reporter)

Updated

4 years ago
Blocks: 926955
blocking-b2g: --- → 1.4?
Whiteboard: [systemsfe]
Assignee: nobody → crdlc
Status: NEW → ASSIGNED
Created attachment 8373396 [details]
Patch v1

I would like to add this unit test to confirm that the algorithm used to calculate the formatted size is ok in Gaia
Attachment #8373396 - Flags: review?(borja.bugzilla)
When I try to download the file described in the bug, the API is saying to us what totalBytes is "-1519423257". I don't know if the bug is in the download manager API or the server is sending a wrong info. 

Aus, could you check it? Thanks a lot
Assignee: crdlc → nobody
Status: ASSIGNED → NEW
Component: Gaia::Settings → General
Flags: needinfo?(aus)
Attachment #8373396 - Flags: review?(kaze)

Comment 3

4 years ago
That would be a bug somewhere in the gecko side of things. Looks like we're converting from a 64 bit int somewhere into a 32 bit value or something like that. Which is lame. Should be easy to fix though. This isn't your bug though. :)
Flags: needinfo?(aus)

Updated

4 years ago
Whiteboard: [systemsfe] → [systemsfe][p=1]

Updated

4 years ago
Assignee: nobody → aus
Summary: [Download Manager]A file with a size >1GB is not displayed successfully → [Downloads API] A file with a size >1GB is not displayed successfully
ok, thanks Ghislain, glad to hear "easy fix" ;)
Comment on attachment 8373396 [details]
Patch v1

Great to see more tests coming!!! R+ for sure!
Attachment #8373396 - Flags: review?(borja.bugzilla) → review+
blocking-b2g: 1.4? → 1.4+
Comment on attachment 8373396 [details]
Patch v1

I agree with Borja. Moar tests.
Attachment #8373396 - Flags: review?(kaze) → review+

Comment 8

4 years ago
Ted, could you have a look at this? I'll be able to give you some more information once I'm online and in MV. This is most likely a bug on the Gecko side of things.
Assignee: aus → tclancy
(Assignee)

Comment 9

4 years ago
Sure, I'll have a look.
(Assignee)

Comment 10

4 years ago
Created attachment 8381774 [details] [diff] [review]
bug-370340.patch
Attachment #8381774 - Flags: review?(khuey)
(Assignee)

Updated

4 years ago
Keywords: checkin-needed
(Assignee)

Updated

4 years ago
Keywords: verifyme
https://hg.mozilla.org/mozilla-central/rev/be2df65a1347
Status: NEW → RESOLVED
Last Resolved: 4 years ago
Resolution: --- → FIXED
Target Milestone: --- → 1.4 S2 (28feb)
(Reporter)

Comment 13

4 years ago
Verified in master branch(1.4)
Status: RESOLVED → VERIFIED

Updated

4 years ago
status-b2g-v1.4: --- → verified
Keywords: verifyme
You need to log in before you can comment on or make changes to this bug.