Closed
Bug 37102
Opened 25 years ago
Closed 25 years ago
ftp://address without a trailing slash returns a blank listing
Categories
(Core :: Networking, defect, P3)
Tracking
()
VERIFIED
FIXED
People
(Reporter: jrgmorrison, Assigned: jud)
References
()
Details
If I go to
ftp://ftp.mozilla.org/pub
I get a blank ftp listing. However, if I add a trailing slash
ftp://ftp.mozilla.org/pub/
then I get the correct listing.
linux 2000042509
Comment 1•25 years ago
|
||
cc-ing Judson, I remember that it makes a difference for the ftp protocol if
there is a slash or not
Comment 2•25 years ago
|
||
What's the expected result: just display it, or add a trailing slash and then
display it?
for consistency this should add a trailing slash and then display it. ->jud
Assignee: gagan → valeski
Assignee | ||
Comment 4•25 years ago
|
||
well, we can't just append one because ftp url's without a trailing slash have
special meaning.
Status: NEW → ASSIGNED
Assignee | ||
Comment 5•25 years ago
|
||
over to waterson. There's something funky going on in the directory viewer
believe it or not.
http://lxr.mozilla.org/seamonkey/source/xpfe/components/directory/nsDirectoryVie
wer.cpp#1158
mInner is null which causes the dir viewer to fail which causes the channel to
be cancelled before it has a chance to push data out.
Assignee: valeski → waterson
Status: ASSIGNED → NEW
Comment 7•25 years ago
|
||
Jud: what do you mean when you say "well, we can't just append one because ftp
url's without a trailing slash have special meaning."
Can't you append the slash to the FTP URL *AFTER* you've determined that its a
directory? This is what I was planning on having the directory viewer do...
however, I'd prefer to see the FTP protocol itself do it.
I'd like to understand what you mean by "special meaning".
Assignee | ||
Comment 8•25 years ago
|
||
FTP servers can interpret a chdir lacking a trailing slash to mean "log the user
into their home directory" and a chdir including a trailing slash to "log the
user into the default directory."
The URL bar should be updated with whatever the URL spec is once the consumer
has received the OnStartRequest callback.
FTP may or may not append a trailing slash, it's up to the server.
Comment 9•25 years ago
|
||
I'm fixing this bug by testing that if its a "ftp://" URL and its a HTTP-INDEX
mimetype, then ensure that the URL ends with a slash.
However, this really seems like something that Necko should be doing instead of
the observer.
Status: NEW → RESOLVED
Closed: 25 years ago
Resolution: --- → FIXED
Comment 10•25 years ago
|
||
(gagan from rjc's desk) jud: what you are saying is only applicable for the root
directory and in this case (as well as any other case) we should update the URL
with the response to CWD command (append to hostname) on the FTP connection. I
think this bug still needs to be fixed from that perspective, reopening.
rjc adds- you might want to back out my changes when you get a chance to fix
this.
Status: RESOLVED → REOPENED
Resolution: FIXED → ---
Assignee | ||
Comment 12•25 years ago
|
||
gagan: no, I'm saying this for whatever the server sends back. the CWD command
may or may not return something with a trailing slash.
Status: NEW → RESOLVED
Closed: 25 years ago → 25 years ago
Resolution: --- → FIXED
Comment 13•25 years ago
|
||
Jud: I'm still confused. (Sorry, long week!) Irregardless of whether CWD returns
something with a trailing slash or not, if CWD succeeds, aren't you guaranteed
that what was returned is a directory? (Meaning, that you could append a slash
if needed.)
You need to log in
before you can comment on or make changes to this bug.
Description
•