Undo History Stays Open After File Closed; Crashes When Used

Bug #525597 reported by Rena Kunisaki
10
This bug affects 2 people
Affects Status Importance Assigned to Milestone
Inkscape
Fix Released
High
John Smith

Bug Description

1) Open or create a file.
2) Open the Undo History window.
3) Make some changes to the file. They do not need to be saved.
4) Open a second file, and close the first.
5) The Undo History window stays open, displaying the actions performed on the first file. Clicking an item in the list crashes Inkscape.

Expected behaviour: The window should switch to display the history of the current document, or close.

Revision history for this message
jazzynico (jazzynico) wrote :

Oops, forgot to test the crash...
I can't reproduce it on Windows XP, Inkscape 0.47 (with basic shapes).
Which Inkscape version is affected by this bug?
Could you please provide the steps that lead to the crash?
Thanks!

Changed in inkscape:
importance: Undecided → Wishlist
status: New → Confirmed
tags: removed: close history
Changed in inkscape:
importance: Wishlist → High
status: Confirmed → Incomplete
Revision history for this message
jazzynico (jazzynico) wrote :

Here's a list of reports which deal with that kind of issue:
https://bugs.launchpad.net/inkscape/+bugs?field.searchtext=crash+undo

tags: added: ui
Revision history for this message
Rena Kunisaki (i-am-inuyasha) wrote :

Version is 0.47 on Debian. Looks like any changes that generate undo history will work.

Revision history for this message
Rena Kunisaki (i-am-inuyasha) wrote :

Here's one reliable way to reproduce this issue:

1) Start Inkscape.
2) Open the Undo History window.
3) Draw a rectangle.
4) Go to File -> New.
5) Close the original window (in which you drew a rectangle) without saving. Note that "Create Rectangle" is still in undo history.
6) Click "[Unchanged]" in the undo history, and Inkscape crashes.

More generally, any time you close a window in which changes were made but keep the Undo History window open, then try to use the undo history, it crashes trying to modify the no-longer-open document.

Revision history for this message
su_v (suv-lp) wrote :

reproduced with Inkscape 0.47 and 0.47+devel r9292 on OS X 10.5.8

console message:

ERROR:document-undo.cpp:254:gboolean sp_document_undo(SPDocument*): assertion failed: (doc->priv != NULL)

Changed in inkscape:
status: Incomplete → Confirmed
Revision history for this message
jazzynico (jazzynico) wrote :

Also reproduced on Ubuntu, Inkscape 0.47 and rev 9295, and on Windows XP, Inkscape 0.47.
But I can't reproduce the crash on Windows XP, Inkscape 0.46. The undo history dialog displays wrong data, but doesn't crash Inkscape if I click on [Unchanged].

tags: added: regression
Revision history for this message
su_v (suv-lp) wrote :

related: bug #378097 “Crashes with several dokument.”

Revision history for this message
Chris Morgan (chris.morgan) wrote :

I reproduced this (without knowledge of this bug report) by reverting a document; its undo history remained and so I clicked on one, expecting it to crash. Then I tried it again in a console to get the error message and it matched the one reported above. Seems like exactly the same bug.

ERROR:document-undo.cpp:254:gboolean sp_document_undo(SPDocument*): assertion failed: (doc->priv != NULL)

Revision history for this message
jazzynico (jazzynico) wrote :

Recent gdb trace attached.

Changed in inkscape:
status: Confirmed → Triaged
Revision history for this message
John Smith (john-smithi) wrote :

Should be fixed by trunk commit r11624.
When floating Undo History should now correctly switch to the active document.

Changed in inkscape:
assignee: nobody → John Smith (john-smithi)
status: Triaged → Fix Committed
Kris (kris-degussem)
Changed in inkscape:
milestone: none → 0.49
Bryce Harrington (bryce)
Changed in inkscape:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.