Bug 406730 - Crash when using Polyline, Rectangle, Ellipse, Poligon tool on Clone layer
Summary: Crash when using Polyline, Rectangle, Ellipse, Poligon tool on Clone layer
Alias: None
Product: krita
Classification: Unclassified
Component: Layer Stack (show other bugs)
Version: nightly build (please specify the git hash!)
Platform: Microsoft Windows Microsoft Windows
: NOR normal
Target Milestone: ---
Assignee: Halla Rempt
Depends on:
Reported: 2019-04-21 12:40 UTC by acc4commissions
Modified: 2019-05-01 13:55 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed In:


Note You need to log in before you can comment on or make changes to this bug.
Description acc4commissions 2019-04-21 12:40:44 UTC
git 8130f8d

I know I'm not supposed to use those on Clone layer but it should display a message or something instead of crash.

Using line tool = Seems to create a Vector layer automatically (Is this intentional?)
Polyline, Rectangle, Ellipse, Poligon = Crash

Windows: Win7
Linux/KDE Plasma: 
(available in About System)
KDE Plasma Version: 
KDE Frameworks Version: 
Qt Version: 

Comment 1 Halla Rempt 2019-04-21 13:06:53 UTC
I can confirm the issue, thanks for the report!
Comment 2 Halla Rempt 2019-04-30 07:43:21 UTC
ASSERT: "d" in file /home/boud/dev/krita/libs/global/kis_shared_ptr.h, line 180

Thread 58 "Thread (pooled)" received signal SIGABRT, Aborted.
[Switching to Thread 0x7fff8d7fa700 (LWP 19761)]
__GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:51
51      ../sysdeps/unix/sysv/linux/raise.c: No such file or directory.
(gdb) bt
#0  __GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:51
#1  0x00007ffff2906801 in __GI_abort () at abort.c:79
#2  0x00007ffff32dbe7b in QMessageLogger::fatal(char const*, ...) const ()
   from /usr/lib/x86_64-linux-gnu/libQt5Core.so.5
#3  0x00007ffff32db671 in qt_assert(char const*, char const*, int) ()
   from /usr/lib/x86_64-linux-gnu/libQt5Core.so.5
#4  0x00007ffff5606c27 in KisSharedPtr<KisPaintDevice>::operator-> (this=<optimized out>)
    at /home/boud/dev/krita/libs/global/kis_shared_ptr.h:180
#5  KisTransactionData::init (this=this@entry=0x7fff7c005c50, device=...)
    at /home/boud/dev/krita/libs/image/kis_transaction_data.cpp:103
#6  0x00007ffff560a81a in KisTransactionData::KisTransactionData (this=0x7fff7c005c50, name=..., device=..., 
    resetSelectionOutlineCache=<optimized out>, parent=<optimized out>)
    at /home/boud/dev/krita/libs/image/kis_transaction_data.cpp:72
#7  0x00007ffff6a9b515 in KisTransaction::KisTransaction (timedID=-1, parent=0x0, device=..., name=..., 
    this=0x7fff7c0014b0) at /home/boud/dev/krita/libs/image/kis_transaction.h:42
#8  KisPainterBasedStrokeStrategy::initStrokeCallback (this=this@entry=0x555562b893c0)
    at /home/boud/dev/krita/libs/ui/tool/strokes/kis_painter_based_stroke_strategy.cpp:264
#9  0x00007ffff6a94b39 in FreehandStrokeStrategy::initStrokeCallback (this=0x555562b893c0)
    at /home/boud/dev/krita/libs/ui/tool/strokes/freehand_stroke.cpp:135
#10 0x00007ffff5702b03 in non-virtual thunk to KisUpdateJobItem::run() ()
   from /home/boud/dev/i-krita/lib/x86_64-linux-gnu/libkritaimage.so.18
#11 0x00007ffff3304352 in ?? () from /usr/lib/x86_64-linux-gnu/libQt5Core.so.5
#12 0x00007ffff32ffbc2 in ?? () from /usr/lib/x86_64-linux-gnu/libQt5Core.so.5
#13 0x00007fffec49f6db in start_thread (arg=0x7fff8d7fa700) at pthread_create.c:463
#14 0x00007ffff29e788f in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:95
Comment 3 Halla Rempt 2019-05-01 13:55:20 UTC
Git commit 96b04eda2b59ecbdd1bcc8bc61b13fe7a71c261e by Boudewijn Rempt.
Committed on 01/05/2019 at 13:54.
Pushed by rempt into branch 'master'.

Warn the user when trying to add a shape to a clone layer

M  +9    -2    libs/ui/tool/kis_tool_polyline_base.cpp
M  +10   -2    libs/ui/tool/kis_tool_rectangle_base.cpp