Update of bug #17536 (project mypaint):
Assigned to: None => martinxyz
_______________________________________________________
Follow-up Comment #6:
Update: actually, zipfile does the right thing. When it gets a unicode
string, it will encode the filename as utf-8 and set the utf-8 bit in the
zip.
Our mistake was that we passed it an utf-8 encoded byte string. Ziplib didn't
have any chance to guess what its encoding was, so it put it literally into
the file, and did not set the utf-8 flag.
When loading the ZIP, such filenames are read back as byte strings, instead
of being decoded as utf-8. Every other ZIP program will assume that filenames
without utf-8 flag are encoded as cp437, so we clearly did it wrong.
With Griatch's fix, we can load such broken ZIP files correctly, however now
we throw an exception if the ZIP file was correct instead. I fixed this in git
master such that we accept both kind of files.
This will screw up if some future application actually encodes filenames as
cp437, however the ORA spec requires UTF-8 for filenames already, so who
cares.
_______________________________________________________
Reply to this item at:
<http://gna.org/bugs/?17536>
_______________________________________________
Nachricht geschickt von/durch Gna!
http://gna.org/
_______________________________________________
Mypaint-bugs mailing list
[email protected]
https://mail.gna.org/listinfo/mypaint-bugs