-
-
Notifications
You must be signed in to change notification settings - Fork 4.7k
fix(Streamer): use localtime for ZIP files #54402
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
Conversation
0b489d8 to
7428b5b
Compare
|
/backport to stable31 |
7428b5b to
6f0e0de
Compare
ZIP does not use a proper timestamp but uses something called "DOS time". This is a weird old format with some limitations like accuracy of only 2 seconds, but also no timezone information. Also unline UNIX time it is not relative to some specific point in time with timezone information, but is always considered to be the local time. Meaning we need to convert it first to the users local time. Signed-off-by: Ferdinand Thiessen <[email protected]>
Signed-off-by: Ferdinand Thiessen <[email protected]>
6f0e0de to
ba00416
Compare
come-nc
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That means users A and B downloading the same zip content will get different time information in there? So if I download stuff and then send it to someone on another time zone times will look wrong on their computer?
Yes and there is no fix - ZIP time is considered the local time of the user that created it. |
Summary
ZIP does not use a proper timestamp but uses something called "DOS time".
This is a weird old format with some limitations like accuracy of only
2 seconds, but also no timezone information.
Also unlike UNIX time it is not relative to some specific point in time
with timezone information, but is always considered to be the local
time. Meaning we need to convert it first to the users local time.
Checklist