-
-
Notifications
You must be signed in to change notification settings - Fork 269
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix incorrect file size display in upload and source interface #2044
Comments
@NSkelsey: this is not a bug, it's just the difference between kb considered as 1000bytes or 1024bytes. I remember you already gone into this discussion, let me refind where it was the clarification. |
Not founding the old conversation but recreating it here. the reason is that the library that we use to print (angular-filter) consider a kB 1024 bytes while your operating system consider a kB 1000 bytes. in the real the two are two different units Kb 1000 (Kilobyte) while the other is KiB 1024 (kibibyte )but in the common use are always misused and called both kilobye: https://en.wikipedia.org/wiki/Kilobyte here the math that solve your issue:
|
Current behavior
When a whistle-blower uploads a file, the reported file size is incorrect. It is not clear if the issue is just in the directive or if the estimation for the file uploader is affected.
Here are some screen shots:
On upload with a comparison of system reported values
Stored and displayed in frontend
Expected behavior
File sizes should match their actual size when downloaded to disk.
Steps to reproduce the problem or feature illustration
Upload a file and observe!
GlobaLeaks version:
Confirmed on v2.70.9
Browser:
Chrome 59
The text was updated successfully, but these errors were encountered: