Closed Bug 149586 Opened 22 years ago Closed 22 years ago

can't open files with a name ending with dot

Categories

(Core :: Networking: File, defect, P3)

defect

Tracking

()

VERIFIED FIXED
mozilla1.2beta

People

(Reporter: marpet, Assigned: darin.moz)

References

Details

(Keywords: testcase, Whiteboard: verify by 1.2b)

Attachments

(1 file)

From Bugzilla Helper:
User-Agent: Mozilla/5.0 (X11; U; Linux i686; pl-PL; rv:1.0.0) Gecko/20020529
BuildID:    2002052918

when you try to open a file with a name of the form XXX. (_with_ the ending dot)
the Mozilla responds that the file couldn't be found.

Reproducible: Always
Steps to Reproduce:
1. create file with a name ending with '.'
2. choose File/Open file
3. select the file from step 1

Actual Results:  error message

Expected Results:  displayed file prefferably with properly recognised content
type :-)

only reproducible on systems which actually allow for filenames with ending dot
(Windows tends to strip this char from the filename) - checked on Debian Linux
(Woody)
confirmed on Linux, 2002073022
Assignee: sgehani → law
Status: UNCONFIRMED → NEW
Component: XP Apps → File Handling
Ever confirmed: true
QA Contact: paw → sairuh
wrong component...
Assignee: law → dougt
Component: File Handling → Networking: File
QA Contact: sairuh → benc
nsBaseURLParser::ParseFilePath doesn't handle this case.  
Assignee: dougt → darin
Severity: normal → minor
Target Milestone: --- → Future
yeah, i guess the URL parser should treat "foo." as the basename instead of what
it currently does: call "foo" the basename and "" the extension.  an empty
extension causes nsIOServiceXXX.cpp to drop the '.' after the file name when
converting from from file:// URL to native file path.  should be easy enough to fix.

-> moz 1.2 beta
Severity: minor → major
Status: NEW → ASSIGNED
Keywords: mozilla1.2, nsbeta1
Priority: -- → P3
Target Milestone: Future → mozilla1.2beta
Attached patch v1 patchSplinter Review
this patch also corrects a potential segmentation violation.  it isn't valid to
dereference (filename + filenameLen)!!
Comment on attachment 100514 [details] [diff] [review]
v1 patch

r=dougt
Attachment #100514 - Flags: review+
Keywords: patch
Comment on attachment 100514 [details] [diff] [review]
v1 patch

sr=jag
Attachment #100514 - Flags: superreview+
Comment on attachment 100514 [details] [diff] [review]
v1 patch

sr=jag
fixed-on-trunk
Status: ASSIGNED → RESOLVED
Closed: 22 years ago
Resolution: --- → FIXED
Whiteboard: verify by 1.2b
Verified.
Status: RESOLVED → VERIFIED
QA Contact: benc → junruh
Summary: can't open files fith a name ending with dot → can't open files with a name ending with dot
+testcase
(also affected Chimera 0.6 and Netscape 7.x, which will remain unfixed)
Keywords: testcase
OS: Linux → All
Hardware: PC → All
You need to log in before you can comment on or make changes to this bug.