Hang with CubicBezierSmooth powerstroke interpolator

Bug #1515993 reported by Parcly Taxel
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Inkscape
Fix Released
High
Unassigned

Bug Description

(Trisquel 7.0, trunk r14461) Open the attached file, then apply the powerstroke LPE to it. The default interpolator applied is CubicBezierFit, which does not hang the program, although the following warnings are printed to STDERR:

** (inkscape:5814): WARNING **: Exception during LPE Power stroke execution.
 lib2geom exception: Invariants violation (./2geom/piecewise.h:155)

** (inkscape:5814): WARNING **: Exception during LPE Power stroke execution.
 lib2geom exception: Invariants violation (./2geom/piecewise.h:155)

Now change the interpolator to CubicBezierSmooth; Inkscape now hangs. Backtrace after SIGINT:
#0 0x00007ffff00c4f24 in _int_free (av=0x7ffff0404760 <main_arena>, p=0x84509c0, have_lock=0) at malloc.c:3814
#1 0x0000000000c8906a in deallocate (this=<optimised out>, __p=<optimised out>) at /usr/include/c++/4.8/ext/new_allocator.h:110
#2 _M_deallocate (this=<optimised out>, __n=<optimised out>, __p=<optimised out>) at /usr/include/c++/4.8/bits/stl_vector.h:174
#3 ~_Vector_base (this=0x7fffffffb5c0, __in_chrg=<optimised out>) at /usr/include/c++/4.8/bits/stl_vector.h:160
#4 ~vector (this=0x7fffffffb5c0, __in_chrg=<optimised out>) at /usr/include/c++/4.8/bits/stl_vector.h:416
#5 ~SBasis (this=0x7fffffffb5c0, __in_chrg=<optimised out>) at ./2geom/sbasis.h:69
#6 RescaleForNonVanishingEnds (MM=..., ZERO=0.0001) at 2geom/sbasis-geometric.cpp:110
#7 0x0000000000c8a668 in Geom::unitVector (V_in=..., tol=tol@entry=0.01, order=order@entry=3) at 2geom/sbasis-geometric.cpp:229
#8 0x00000000007b5bd5 in Geom::touching_circle (curve=..., tol=0.01, t=0) at live_effects/lpe-powerstroke.cpp:114
#9 0x00000000007b644e in Inkscape::LivePathEffect::path_from_piecewise_fix_cusps (B=..., y=..., jointype=jointype@entry=Inkscape::LivePathEffect::LINEJOIN_EXTRP_MITER_ARC, miter_limit=4, tol=0.01)
    at live_effects/lpe-powerstroke.cpp:424
#10 0x00000000007b8cbf in Inkscape::LivePathEffect::LPEPowerStroke::doEffect_path (this=0x84e6400, path_in=...) at live_effects/lpe-powerstroke.cpp:640
#11 0x000000000073e8cb in Inkscape::LivePathEffect::Effect::doEffect (this=0x84e6400, curve=0x84dfce0) at live_effects/effect.cpp:524
#12 0x00000000005844ca in SPLPEItem::performPathEffect (this=this@entry=0x8118fe0, curve=curve@entry=0x84dfce0) at sp-lpe-item.cpp:254
#13 0x00000000005a2d90 in SPPath::update_patheffect (this=0x8118fe0, write=<optimised out>) at sp-path.cpp:340
#14 0x0000000000584859 in sp_lpe_item_update_patheffect (lpeitem=<optimised out>, wholetree=<optimised out>, write=<optimised out>) at sp-lpe-item.cpp:325
#15 0x000000000059ec94 in emit (_A_a2=@0x7fffffffc98c: 1, _A_a1=@0x7fffffffc998: 0x80c6b40, impl=0x838fd20) at /usr/include/sigc++-2.0/sigc++/signal.h:1252
#16 emit (this=0x80c6be8, _A_a2=@0x7fffffffc98c: 1, _A_a1=@0x7fffffffc998: 0x80c6b40) at /usr/include/sigc++-2.0/sigc++/signal.h:2891
#17 SPObject::emitModified (this=this@entry=0x80c6b40, flags=flags@entry=0) at sp-object.cpp:1236
#18 0x0000000000550528 in SPDefs::modified (this=<optimised out>, flags=0) at sp-defs.cpp:68
#19 0x000000000059ebf0 in SPObject::emitModified (this=this@entry=0x8177400, flags=flags@entry=0) at sp-object.cpp:1234
#20 0x0000000000577f61 in SPGroup::modified (this=this@entry=0x7bc0a30, flags=0, flags@entry=2) at sp-item-group.cpp:213
#21 0x00000000005ab740 in SPRoot::modified (this=0x7bc0a30, flags=2) at sp-root.cpp:301
#22 0x000000000059ebf0 in SPObject::emitModified (this=0x7bc0a30, flags=flags@entry=0) at sp-object.cpp:1234
#23 0x00000000004abbba in SPDocument::_emitModified (this=this@entry=0x1e5e4e0) at document.cpp:1003
#24 0x00000000004ac36a in SPDocument::_updateDocument (this=this@entry=0x1e5e4e0) at document.cpp:1170
#25 0x00000000004ac4a7 in SPDocument::ensureUpToDate (this=this@entry=0x1e5e4e0) at document.cpp:1193
#26 0x00000000004b9f1d in Inkscape::DocumentUndo::maybeDone (doc=doc@entry=0x1e5e4e0, key=key@entry=0x0, event_type=239, event_description=...) at document-undo.cpp:153
#27 0x00000000004ba40c in Inkscape::DocumentUndo::done (doc=doc@entry=0x1e5e4e0, event_type=<optimised out>, event_description=...) at document-undo.cpp:99

Revision history for this message
Parcly Taxel (parclytaxel-deactivatedaccount) wrote :
Revision history for this message
Alvin Penner (apenner) wrote :

hang reproduced on Windows XP, Inkscape 0.91+devel r14391 (Oct 2 2015)

I was not able to produce a backtrace.

Changed in inkscape:
status: New → Confirmed
su_v (suv-lp)
tags: added: 2geom
Changed in inkscape:
importance: Undecided → High
milestone: none → 0.92
Revision history for this message
su_v (suv-lp) wrote :

Reproduced with Inkscape 0.91+devel r14461 on OS X 10.7.5.

Based on tests with archived builds:
- hang not reproduced with rev <= 14293,
- hang reproduced with rev >= 14299;
what appears to be a regression in trunk is likely related to the changes in r14299:
https://bazaar.launchpad.net/~inkscape.dev/inkscape/trunk/changes/14299

Revision 14299: 2Geom: update to r2422.
Fixes LP #1482806: crash on Pattern along Path with horizontal segments.
https://bazaar.launchpad.net/~inkscape.dev/inkscape/trunk/revision/14299

Changed in inkscape:
status: Confirmed → Triaged
tags: added: regression
Revision history for this message
su_v (suv-lp) wrote :

Full backtrace with debug build (r14434)

Revision history for this message
jazzynico (jazzynico) wrote :

Inkscape still hangs on Windows XP (32-bit), Inkscape 14648 (after the 2geom update rev. 14639, see http://bazaar.launchpad.net/~inkscape.dev/inkscape/trunk/revision/14639).

Revision history for this message
Jabiertxof (jabiertxof) wrote :

Not reproduced with 0.92.x r15080. Debian stretch.

Revision history for this message
jazzynico (jazzynico) wrote :

Fix confirmed on Windows 7, lp:inkscape/0.92.x rev. 15080.

Changed in inkscape:
milestone: 0.92 → none
status: Triaged → 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.