Undo crash and von Koch LPE

Bug #456503 reported by Alexandre Prokoudine
30
This bug affects 4 people
Affects Status Importance Assigned to Milestone
Inkscape
Fix Released
High
Jabiertxof

Bug Description

When I try to undo changing fill for a color stop of a gradient that is applied to an object with von Koch LPE, Inkscape crashes. Here is the backtrace from gdb:

** (inkscape:1318): CRITICAL **: virtual void Inkscape::EventLog::notifyRedoEvent(Inkscape::Event*): assertion `_getRedoEvent() && (*(_getRedoEvent()))[_columns.event] == log' failed

** (inkscape:1318): CRITICAL **: virtual void Inkscape::EventLog::notifyRedoEvent(Inkscape::Event*): assertion `_getRedoEvent() && (*(_getRedoEvent()))[_columns.event] == log' failed

** (inkscape:1318): CRITICAL **: virtual void Inkscape::EventLog::notifyRedoEvent(Inkscape::Event*): assertion `_getRedoEvent() && (*(_getRedoEvent()))[_columns.event] == log' failed
**
gtkmm:ERROR:treeiter.cc:214:const Gtk::TreeNodeChildren& Gtk::TreeRow::children() const: assertion failed: (!is_end_)

Program received signal SIGABRT, Aborted.
[Switching to Thread 0x7f0a868297c0 (LWP 1318)]
0x00007f0a7e358fd5 in raise () from /lib/libc.so.6
(gdb) bt
#0 0x00007f0a7e358fd5 in raise () from /lib/libc.so.6
#1 0x00007f0a7e35ab43 in abort () from /lib/libc.so.6
#2 0x00007f0a81f1bd43 in g_assertion_message () from /usr/lib/libglib-2.0.so.0
#3 0x00007f0a81f1c1e2 in g_assertion_message_expr () from /usr/lib/libglib-2.0.so.0
#4 0x00007f0a86326c2e in Gtk::TreeRow::children () from /usr/lib/libgtkmm-2.4.so.1
#5 0x00000000008043b7 in Inkscape::UI::Dialog::UndoHistory::_onListSelectionChange (this=0xce58e00) at ui/dialog/undo-history.cpp:278
#6 0x00007f0a852be202 in Glib::SignalProxyNormal::slot0_void_callback () from /usr/lib/libglibmm-2.4.so.1
#7 0x00007f0a827a025d in g_closure_invoke () from /usr/lib/libgobject-2.0.so.0
#8 0x00007f0a827b646e in ?? () from /usr/lib/libgobject-2.0.so.0
#9 0x00007f0a827b7608 in g_signal_emit_valist () from /usr/lib/libgobject-2.0.so.0
#10 0x00007f0a827b7b33 in g_signal_emit () from /usr/lib/libgobject-2.0.so.0
#11 0x00007f0a845146f1 in ?? () from /usr/lib/libgtk-x11-2.0.so.0
#12 0x00007f0a8451d65f in ?? () from /usr/lib/libgtk-x11-2.0.so.0
#13 0x00007f0a8442b908 in ?? () from /usr/lib/libgtk-x11-2.0.so.0
#14 0x00007f0a827a025d in g_closure_invoke () from /usr/lib/libgobject-2.0.so.0
#15 0x00007f0a827b5c3b in ?? () from /usr/lib/libgobject-2.0.so.0
#16 0x00007f0a827b748a in g_signal_emit_valist () from /usr/lib/libgobject-2.0.so.0
#17 0x00007f0a827b7b33 in g_signal_emit () from /usr/lib/libgobject-2.0.so.0
#18 0x00007f0a8452e74e in ?? () from /usr/lib/libgtk-x11-2.0.so.0
#19 0x00007f0a84424273 in gtk_propagate_event () from /usr/lib/libgtk-x11-2.0.so.0
#20 0x00007f0a84425393 in gtk_main_do_event () from /usr/lib/libgtk-x11-2.0.so.0
#21 0x00007f0a840a806c in ?? () from /usr/lib/libgdk-x11-2.0.so.0
#22 0x00007f0a81ef5d3b in g_main_context_dispatch () from /usr/lib/libglib-2.0.so.0
#23 0x00007f0a81ef950d in ?? () from /usr/lib/libglib-2.0.so.0
#24 0x00007f0a81ef9a3d in g_main_loop_run () from /usr/lib/libglib-2.0.so.0
#25 0x00007f0a844257a7 in gtk_main () from /usr/lib/libgtk-x11-2.0.so.0
#26 0x0000000000453cf9 in sp_main_gui (argc=1, argv=0x7fff8e871d38) at main.cpp:949
#27 0x000000000045327e in main (argc=1, argv=0x7fff8e871d38) at main.cpp:685

The bug is 100% reproducible on Ubuntu 8.10 with SVN checkout from 19th of October 2009.

Revision history for this message
Alexandre Prokoudine (alexandre-prokoudine) wrote :
Download full text (4.3 KiB)

I do have a suspicion that it is a general undo bug for LPEs. Here is a backtrace from gdb for a crash when you try to undo an envelope deformation LPE:

#0 Geom::sbasis_to_bezier (bz=@0x7fff88841da0, sb=@0x7fff888421c8, sz=<value optimized out>) at ./2geom/sbasis.h:75
#1 0x0000000000a8ab4d in Geom::sbasis_to_bezier (bz=@0x7fff88841ff0, sb=@0x7fff888421b0, sz=4)
    at 2geom/sbasis-to-bezier.cpp:164
#2 0x0000000000a8ae0a in Geom::build_from_sbasis (pb=@0x7fff88842140, B=@0x7fff888421b0, tol=0.01,
    only_cubicbeziers=<value optimized out>) at 2geom/sbasis-to-bezier.cpp:351
#3 0x0000000000a8ba05 in Geom::path_from_piecewise (B=@0x7fff888424c0, tol=0.01, only_cubicbeziers=200)
    at 2geom/sbasis-to-bezier.cpp:406
#4 0x000000000064b16a in Inkscape::LivePathEffect::Effect::doEffect_path (this=0xbe95a20, path_in=@0x7fff888425f0)
    at live_effects/effect.cpp:399
#5 0x000000000064a463 in Inkscape::LivePathEffect::Effect::doEffect (this=0xbe95a20, curve=0xa89a580)
    at live_effects/effect.cpp:371
#6 0x00000000004cce6a in sp_lpe_item_perform_path_effect (lpeitem=0x9d61dc0, curve=0xa89a580) at sp-lpe-item.cpp:342
#7 0x00000000004c4224 in sp_group_perform_patheffect (group=<value optimized out>, topgroup=0x9d61dc0, write=true)
    at sp-item-group.cpp:880
#8 0x00000000004cd313 in sp_lpe_item_update_patheffect (lpeitem=0xbe005a0, wholetree=true, write=false) at sp-lpe-item.cpp:405
#9 0x00000000004db336 in sp_path_set_original_curve (path=0xbe005a0, curve=0x0, owner=1, write=200) at sp-path.cpp:468
#10 0x00000000004dc64e in sp_path_set (object=0xbe005a0, key=<value optimized out>, value=<value optimized out>)
    at sp-path.cpp:273
#11 0x00000000004d425a in sp_object_repr_attr_changed (key=0x2d95c40 "inkscape:original-d", is_interactive=false,
    data=<value optimized out>) at sp-object.cpp:1084
#12 0x000000000096dca8 in Inkscape::XML::CompositeNodeObserver::notifyAttributeChanged (this=0x957b150, node=@0x957b1d0,
    name=3040, old_value=<value optimized out>, new_value=<value optimized out>) at xml/composite-node-observer.cpp:94
#13 0x000000000071d2ab in Inkscape::XML::SimpleNode::setAttribute (this=0x957b100, name=<value optimized out>,
    value=<value optimized out>) at xml/simple-node.cpp:356
#14 0x000000000071dba4 in Inkscape::XML::undo_log_to_observer (log=<value optimized out>, observer=@0xfd6190)
    at xml/event.h:105
---Type <return> to continue, or q <return> to quit---
#15 0x000000000071ea60 in sp_repr_undo_log (log=0x9592700) at xml/event.cpp:148
#16 0x000000000045d8dd in sp_document_undo (doc=0x1bbdf00) at document-undo.cpp:267
#17 0x000000000080424f in Inkscape::UI::Dialog::UndoHistory::_onListSelectionChange (this=0xbe1b3e0)
    at ui/dialog/undo-history.cpp:251
#18 0x00007fdb7f290202 in Glib::SignalProxyNormal::slot0_void_callback () from /usr/lib/libglibmm-2.4.so.1
#19 0x00007fdb7c77225d in g_closure_invoke () from /usr/lib/libgobject-2.0.so.0
#20 0x00007fdb7c78846e in ?? () from /usr/lib/libgobject-2.0.so.0
#21 0x00007fdb7c789608 in g_signal_emit_valist () from /usr/lib/libgobject-2.0.so.0
#22 0x00007fdb7c789b33 in g_signal_emit () from /usr/lib/libgobject-2.0.so.0
#23 0x00007fdb7e4e66f1 in ?? () from /usr/lib/lib...

Read more...

su_v (suv-lp)
tags: added: livepatheffects undo
Revision history for this message
Johan Engelen (johanengelen) wrote :

Yep, it's a general LPE undo issue.
Don't undo :P (really, I'm sorry :(

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

recent related bug report comments about LPE undo crashes:
Bug #365903 in Inkscape: “lpe-knot for groups”: comments 8 + 9

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

Setting report to 'Confirmed' based on Johan's comment #2

Changed in inkscape:
importance: Undecided → High
status: New → Confirmed
Revision history for this message
Formerly Kevin Yin, now disabled (kyin) wrote :

If you do undo, don't save! Your file could be in trouble, since what you see might not be what is saved. (or, save to a separate file)

Revision history for this message
Jabiertxof (jabiertxof) wrote :

the fix in bug #540591 also fix this

Revision history for this message
Jabiertxof (jabiertxof) wrote :

Fixed on r.14975

Changed in inkscape:
status: Confirmed → Fix Committed
jazzynico (jazzynico)
Changed in inkscape:
assignee: nobody → Jabiertxof (jabiertxof)
milestone: none → 0.92
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.