Hi,

I've noticed that search results with UTF-8 encoded filenames are
correctly displayed at the search pane but are mangled at the download
pane. The reason for this is escape_filename() in fileinfo.c. If all
characters which match iscntrl() are replaced by an underscore, the
encoding is broken. The only real bad characters I can think about
are '\e' and '\n'. Actually, the escaping is only meant to save the
user because depending on how he resp. other software handles filenames,
control characters could cause subtle security problems. So, in general,
there would be nothing *wrong* if GTKG simply used the filenames as-is.

Is there any simple way to strip the control characters and still preserve
the valid encoding?

What's worse is that GTKG seems to attempt downloading such files by name
instead of urn:sha1 which fails (of course?).

-- 
Christian

Attachment: pgpdbgA4w5dIY.pgp
Description: PGP signature

Reply via email to