Closed
Bug 165585
Opened 23 years ago
Closed 23 years ago
[TRUNK] FTP listing is not working properly for native filename, unable to download
Categories
(Core :: Internationalization, defect)
Tracking
()
VERIFIED
FIXED
People
(Reporter: ji, Assigned: dougt)
Details
(Keywords: intl, regression)
Attachments
(2 files)
|
15.04 KB,
image/jpeg
|
Details | |
|
1.34 KB,
patch
|
nhottanscp
:
review+
darin.moz
:
superreview+
|
Details | Diff | Splinter Review |
FTP listing used to be working for native filename as long as browser default
charset matches with server's locale. Now it's broken in the trunk since
2002-08-29-04-trunk build
Steps to reproduce:
1. go to ftp://10.169.114.243, this testing server is now running on Simplified
Chinese XP, the listing page contains several files with Chinese filename.
2. Set brower's default charset to gb2312 via Edit | Preferences | Navigator |
Languages
you can see the listing page doesn't list the chinese filename at all. It used
to be working before.
3. Change the default charset setting to gb18030, the Chinese filename is listed,
then click on one .exe file, it can't be downloaded, giving out an error message
indicating that the file doesn't exist, which is not true.
Comment 2•23 years ago
|
||
Comment 3•23 years ago
|
||
so is this fixed?
| Assignee | ||
Comment 5•23 years ago
|
||
this is strange. I can browse that site without any problem in my build. Auto
Detect is off. Could there be any other change which you have made which caused
this to break?
In my case, auto detect is also turned off. Can you click and download the file
with the filename beginning with "icq"?
Comment 7•23 years ago
|
||
>I can browse that site without any problem in my build.
The site has 12 files/directories. I can only see three directories which are
ASCII only, cannot see non ASCII files/directories.
| Assignee | ||
Comment 8•23 years ago
|
||
I see. you have to go into perferences and change the charset there.
| Assignee | ||
Comment 10•23 years ago
|
||
turns out that this regression was not caused by my changes, but as a result of
this checking:
date: 2002/05/22 00:00:37; author: yokoyama%netscape.com; state: Exp; lines:
+16 -4
bug 118179
FTP site is broken for Japanese server
Impact for only displaying ftp directory listing.
/r=bbaetz,/sr=darin,/a=chofmann,/adt=putterman
Backing out this file:
mozilla/netwerk/streamconv/converters/nsDirIndexParser.cpp
Fixes the problem.
Not that this bustage probably occurs on the BRANCH!
Comment 11•23 years ago
|
||
That change is needed for the listing page to use the pref default charset
instead of always "ISO-8859-1".
Without that change, the user always has to set the charset by menu in order to
see it right.
We need to figure out why that change does not work well with the change of bug
95590 and find a solution.
Comment 12•23 years ago
|
||
(why did bug 118179 end up as INVALID instead of FIXED???)
Anyway, doug, the 'new' code probably needs to translate the filename through
nsITextTOSuburi - I _think_ thats what the old code did, although there were/are
so many layers of indirection that I'n not sure about that.
The basic problem here is that FTP was not designed to handle anything apart
from 7-bit-ASCII. The support we have for trying to work arround this is
incredibly fragile because the ftp spec gives us no other way to handle it....
| Assignee | ||
Comment 13•23 years ago
|
||
You are right. All we have to do is make sure that the filename is properly
encoded. I think that this code be cleaned up alot (cache the encoding, or
better yet make the location a wide string....)
Can someone verify this patch?
Comment 14•23 years ago
|
||
I think the patch fixed the problem. I can see the Chinese ftp listing correctly
when I set the browser's default to GB2311.
Let me switch my system to Chinese to verify if I can really download the files.
Comment 15•23 years ago
|
||
With setting my default system charset to Simplified Chinese, I can download the
Chinese named files in ftp://10.169.114.243 if I applied the patch.
Comment 16•23 years ago
|
||
Comment on attachment 97357 [details] [diff] [review]
Fixes problem
r=nhotta
Attachment #97357 -
Flags: review+
Comment 17•23 years ago
|
||
Comment on attachment 97357 [details] [diff] [review]
Fixes problem
sr=darin
Attachment #97357 -
Flags: superreview+
| Assignee | ||
Comment 18•23 years ago
|
||
Fixed
Status: NEW → RESOLVED
Closed: 23 years ago
Resolution: --- → FIXED
| Reporter | ||
Comment 19•23 years ago
|
||
Verified as fixed on 09/06 trunk build.
Status: RESOLVED → VERIFIED
You need to log in
before you can comment on or make changes to this bug.
Description
•