Closed
Bug 102921
Opened 24 years ago
Closed 24 years ago
Mozilla crashes when Cache in profile dir points to nonexistent directory
Categories
(Core :: Networking: Cache, defect, P2)
Tracking
()
VERIFIED
FIXED
mozilla0.9.9
People
(Reporter: hramrach, Assigned: gordon)
Details
(Keywords: crash, Whiteboard: patch)
Attachments
(1 file)
563 bytes,
patch
|
darin.moz
:
superreview+
|
Details | Diff | Splinter Review |
To reproduce:
1)Make a Mozilla profile
2)Terminate Mozilla
3)Remove Cache dir from your profile
4)Make Cache a symlink pointing to a nonexistenet location
5)Re-run Mozilla
Result:
crash
Expected:
error report, cache disabling?
![]() |
||
Comment 1•24 years ago
|
||
I think this goes in the category of "Don't Do That". :)
Status: UNCONFIRMED → NEW
Ever confirmed: true
Seems like we should at least make this not crash. Targeting for 0.9.6.
Target Milestone: --- → mozilla0.9.6
Moving to 0.9.8, when necko will be focusing on stability.
Target Milestone: mozilla0.9.6 → mozilla0.9.8
We call nsIFile::Exists() to determine if we need to create the Cache
directory. In the case of a symbolic link to a non-existant ojbect, Exists()
calls access() which returns false. However, the subsequent Create() fails
because the existence of the link prevents the creation of a new directory.
The crash occured because nsDiskCacheDevice::Init() presumed mCacheDirectory
was valid. I've added a line to return an error if this isn't true. The
result is to disable the disk cache if it believes it needs to create a new
cache directory, but can't for some reason.
Comment 5•24 years ago
|
||
Comment on attachment 70240 [details] [diff] [review]
disable disk cache if we can't create Cache directory.
sr=darin
Attachment #70240 -
Flags: superreview+
Patch checked in. Marking FIXED.
Status: NEW → RESOLVED
Closed: 24 years ago
Resolution: --- → FIXED
You need to log in
before you can comment on or make changes to this bug.
Description
•