Closed Bug 70312 Opened 25 years ago Closed 25 years ago

Bookmarks deleted on exit

Categories

(Core :: XPCOM, defect)

defect
Not set
critical

Tracking

()

VERIFIED FIXED
mozilla0.9

People

(Reporter: gilles+mozilla, Assigned: naving)

References

()

Details

(Keywords: dataloss, regression, smoketest)

Attachments

(2 files)

2001022621 trunk After closing mozilla and restarting Mozilla, my bookmarks completely disappeared. To reproduce, first make a copy of your bookmark. Open mozilla. Close mozilla. Look at the bookmark file. Here's what I got: <!DOCTYPE NETSCAPE-Bookmark-file-1> <!-- This is an automatically generated file. It will be read and overwritten. Do Not Edit! --> <META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=UTF-8"> <TITLE>Bookmarks</TITLE> <H1>Bookmarks</H1> <DL><p> <DT><H3 I took the bookmark file from my computer at home which is on windows (but I never had problems until today)
No problem with 2001022609
It's seen on Win98 2001022622-Mtrunk. (Perhaps it isn't only bookmarks problem, my cookies also disappeared.
2001022621 linux SEA: Bookmarks trunkated. Raising severity to blocker. Smoketest + dataloss keyword.
Severity: critical → blocker
Keywords: dataloss, smoketest
OS: Linux → All
Oh sh*t, confirming on Mozilla/5.0 (X11; U; Linux 2.2.18pre11-va1.8 i686; en-US; 0.9) Gecko/20010220 CVS build from now (which is 02/27/01, 1 pm. GMT+1) It seems to happen at exit, no matter whether you "imported" your NS 4.x bookmarks or just copied them into your profile. On exit they're nuked/truncated as described above. For the record, on startup Mozilla complains about the truncated bookmark file: Start reading in bookmarks.html ###!!! ASSERTION: |CharAt| out-of-range: 'aIndex<Length()', file ../../dist/include/nsAReadableString.h, line 612 ###!!! Break: at file ../../dist/include/nsAReadableString.h, line 612 Finished reading in bookmarks.html (6776 microseconds) ... but that's probably to be expected if the file is corrupt. (Can we have a synonym for Severity:blocker to "utterly annoying" ?? ;-)
New bookmarks made during a session are not saved to disk.
(Maybe stupid) comment : Could this be caused by the fix for bug 69862 ?
for me it had always rewrote an empty bookmark file on exit, no matter if I either imported bookmarks, added some, deleted some, or didn't do anything with my bookmarks. but since I deleted the bookmark file it doesn't create a new one, shouldn't it?
I looked and everything looks completely innocent to me. Some checkin must've "revealed" this bug. Adding regression keyword...
Keywords: regression
I see this for my bookmarks as well as my preferences file. I commented out (in nsFileStream.cpp) the body of the destructor method for nsOutputFileStream() and I don't seem to get these files corrupted/deleted anymore. Reassign to naving for investigation.
Assignee: ben → naving
Component: Bookmarks → XPCOM
Hardware: PC → All
Target Milestone: --- → mozilla0.9
Cookies and bookmarks lost on a cvs build from yesterday evening here as well.
This is a regression of the checkin from bug 69862. cc'ing bienvenu@netscape.com, reviewer for that patch and setting URL to the location for that checkin.
my suggestion is to comment out the code in the output stream destructor until we figure out why the bookmarks code is creating an empty output stream.
I think we should back out it until we know what's wrong. (I guess that was what bienvenu suggest?)
david, can you check in your "commenting out" after checking to see if the problem goes away with that code gone?
My own (possibly stupid) suggestion: Does putting a fflush() equivalent before the close() make the problem go away? If close() itself is supposed to flush all buffers, perhaps a buggy implementation somewhere is not doing so...
leaf, I'm not on the trunk, so I can't check anything in (at least not for an hour or two). Perhaps Kathy or someone else who's tried it can check it in. Re Stuart's comment, it's certainly a possibility that putting an fflush could fix this if we have buggy streams, but we should try that after backing out/commenting out the changes.
Ok, I commented out the lines and it "fixed" the problem. Patch coming up... BTW, this filestream issue also horks cookies it seems.
timeless' patch looks good to me. And presumably you tried it and it fixed the problem?
r=hwaara it fixed it for me as well.
fix checked in
Status: NEW → RESOLVED
Closed: 25 years ago
Resolution: --- → FIXED
Reopening per leaf. The original problem, that naving hopefully will take care of, isn't fixed.
Status: RESOLVED → REOPENED
Resolution: FIXED → ---
Was the checkin a long term fix or a short term fix? If it was a short term fix do we have a bug to do the long term fix? "Sheriff for a day"
This is a short-term fix. The assignee of this bug will attempt to create the long-term fix.
Thanks to timeless and Waara for helping out. Perhaps we need to check and close the streams only in mailnews rather than across the board.
the "cookies" part of this bug is bug 70316. Dup it?
*** Bug 70316 has been marked as a duplicate of this bug. ***
respins showing bookmarks beeing kept after exit... but the bookmarks are showing as "blank menu item" perhaps this is related to bug 70329 or bug 4070??
Lowering severity since we have a temporary fix.
Severity: blocker → critical
*** Bug 70359 has been marked as a duplicate of this bug. ***
*** Bug 70448 has been marked as a duplicate of this bug. ***
The build comments section says that this is fixed, but using build 2001022705, my bookmarks and cookies are still deleted on exit.
Just downloaded 2001022705 (mozilla-win32.zip) and it deleted all my bookmarks.
the bug was fixed after the 5 o clock build. The 21 o clock build from the 27th keep my bookmarks alive!
Can I resolve you two as dupes of mozilla should display content before downloading? let's look at the facts. timeless@mac.com checked in a fix at 2001-02-27 10:02 You grabbed a build from 2001 02 27 05 and you expect it to work? please grab a build from _after_ the checkin. naving: i suggest you file a new bug for whatever problem we were facing that caused a need for this fix. this bug is too spammed.
Status: REOPENED → RESOLVED
Closed: 25 years ago25 years ago
Resolution: --- → FIXED
There is already a bug for that. #69862
just to screw with your minds: i'm using win32 mtrunk installer build 2001022705, which theoretically doesn't have the fix checked in, and i have no bookmark or cookie loss problems at all. fixes landing before they are checked in? time has no meaning when you find yourself caught in <embed spooky music><i>the mozilla zone....</i>
Works for me now. Verifying...
Status: RESOLVED → VERIFIED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: