Closed
Bug 608524
Opened 14 years ago
Closed 8 years ago
Download manager gets file sizes wrong.
Categories
(Firefox :: Downloads Panel, defect)
Tracking
()
RESOLVED
WONTFIX
People
(Reporter: iain, Unassigned)
Details
(Keywords: polish)
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.6; rv:2.0b6) Gecko/20100101 Firefox/4.0b6
Build Identifier: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.6; rv:2.0b6) Gecko/20100101 Firefox/4.0b6
The download manager gives file sizes that are inconsistent size of the downloaded file reported by Mac OS X Finder (version 10.6.5). I noticed this when I downloaded a 9.5 MB file from the web; downloaded manager listed the file size as 9.1 MB.
I believe this bug is caused by two different definitions of the unit: megabyte.
The Mac OS X Finder uses decimal file size units in which 1 megabyte is 1,000,0000 bytes.
I suspect Firefox uses binary file size units in which 1 megabyte is 1,048,576 bytes (1024x1024 bytes).
Reproducible: Always
Steps to Reproduce:
1. Download a file from the web.
2. Once downloaded is completed write down the download's file size shown in the 'Downloads' window.
3. Find the file in Mac OS X Finder.
4. Open the "Get Info" window and compare the file size with what you wrote down in step 2.
Actual Results:
The file size shown in the 'Downloads' window (Download Manager in Firefox) is different to the file size should in the 'Get Info' window (Finder).
Expected Results:
The two file sizes—Firefox's and Finder's—should be identical.
Reporter | ||
Comment 1•14 years ago
|
||
Correction: The Mac OS X Finder uses decimal file size units in which 1 megabyte is 1,000,000 bytes (not 1,000,0000 bytes).
Comment 2•14 years ago
|
||
In 10.6 Apple changed from using 2^20 bytes == 1 MB to 10^6 == 1 MB. The code in question (http://mxr.mozilla.org/mozilla-central/source/toolkit/mozapps/downloads/DownloadUtils.jsm#398) is clearly using 2^20 bytes == 1 MB.
One may argue that mozilla should use MiB instead, but that'd be bug 106618. Not sure we really care to fix this just for one platform.
Updated•14 years ago
|
Version: unspecified → 4.0 Branch
Comment 3•14 years ago
|
||
This bug was reported using a pre-release version of Firefox 4. Now that Firefox 4.0.1 final has been released, can you please update and retest your bug? A fresh profile would be a good starting place to test,
http://support.mozilla.com/kb/Managing+profiles. If you continue to see the issue, can you please update this bug with your results?
Filter: firefox4prebugsunco
Reporter | ||
Comment 4•14 years ago
|
||
I just tested this with Firefox 4.0.1 for Mac by downloadeding a file from the web.
The "Downloads" window in Firefox says the file was 28.1 MB.
Mac OS X says the file was 29.5 MB.
Typing 'ls -l' shows that the actual size of the file is: 29 491 920 bytes.
According to Wikipedia, when referring to "computer storage" there are 1 000 000 bytes in a megabyte. If Wikipedia is an authority on this then the correct file size is 29.5 MB.
Conclusion: Firefox 4.0.1 for Mac reports file sizes wrong in the Downloads window.
Comment 5•8 years ago
|
||
Do you still see this problem?
Component: General → Downloads Panel
Flags: needinfo?(iain)
Reporter | ||
Comment 6•8 years ago
|
||
I'll give it a try and see.
Comment 7•8 years ago
|
||
I'm currently looking at old bugs related to downloads and helping to make clear decisions about them. Sorry for the delay between this response and Wayne's question in comment 5.
Following up to comment 2, I think we shouldn't fix this even if it's still reproducible. If the reported file size is slightly different than the one reported by the system file manager, it's reasonable to assume this won't make a difference in the overall user experience. It's more important for the value to be consistent across all users of Firefox, regardless of platform, for debugging and support purposes.
Status: UNCONFIRMED → RESOLVED
Closed: 8 years ago
Flags: needinfo?(iain)
Resolution: --- → WONTFIX
You need to log in
before you can comment on or make changes to this bug.
Description
•