Bug 384958

Summary: Krita crashes when closed while loading
Product: [Applications] krita Reporter: Davide Ferracin <dv.ferracin>
Component: GeneralAssignee: Krita Bugs <krita-bugs-null>
Status: RESOLVED FIXED    
Severity: crash CC: halla
Priority: NOR Keywords: drkonqi
Version: 3.2.1   
Target Milestone: ---   
Platform: Arch Linux   
OS: Linux   
Latest Commit: Version Fixed In:

Description Davide Ferracin 2017-09-22 12:04:38 UTC
Application: krita (3.2.1)

Qt Version: 5.9.1
Frameworks Version: 5.37.0
Operating System: Linux 4.10.17-2-MANJARO i686
Distribution: "Manjaro Linux"

-- Information about the crash:
- What I was doing when the application crashed:

I opened Krita by mistake, so  I clicked on the red X button to close it (on the main window) before the loading process was complete.
There were some issues previous to the error (Krita had not been opened yet) such as a full /home partition and "write errors" in GIMP due to the memory being full.

-- Backtrace:
Application: Krita (krita), signal: Segmentation fault
Using host libthread_db library "/usr/lib/libthread_db.so.1".
[Current thread is 1 (Thread 0xb0d1a2c0 (LWP 11428))]

Thread 6 (Thread 0xa4811b40 (LWP 11436)):
#0  0xb77accd9 in __kernel_vsyscall ()
#1  0xb3dd4290 in pthread_cond_wait@@GLIBC_2.3.2 () from /usr/lib/libpthread.so.0
#2  0xb5c7095e in QWaitCondition::wait(QMutex*, unsigned long) () from /usr/lib/libQt5Core.so.5
#3  0xb5c68ba3 in QSemaphore::tryAcquire(int, int) () from /usr/lib/libQt5Core.so.5
#4  0xb4c7722e in KisTileDataSwapper::waitForWork() () from /usr/lib/libkritaimage.so.17
#5  0xb4c774a4 in KisTileDataSwapper::run() () from /usr/lib/libkritaimage.so.17
#6  0xb5c6f49d in ?? () from /usr/lib/libQt5Core.so.5
#7  0xb3dcde62 in start_thread () from /usr/lib/libpthread.so.0
#8  0xb596bd96 in clone () from /usr/lib/libc.so.6

Thread 5 (Thread 0xa9414b40 (LWP 11432)):
#0  0xb77accd9 in __kernel_vsyscall ()
#1  0xb596144f in poll () from /usr/lib/libc.so.6
#2  0xb367eb00 in g_poll () from /usr/lib/libglib-2.0.so.0
#3  0xb366f95a in ?? () from /usr/lib/libglib-2.0.so.0
#4  0xb366fa94 in g_main_context_iteration () from /usr/lib/libglib-2.0.so.0
#5  0xb5ea0cf5 in QEventDispatcherGlib::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib/libQt5Core.so.5
#6  0xb5e3e63e in QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib/libQt5Core.so.5
#7  0xb5c6a1c9 in QThread::exec() () from /usr/lib/libQt5Core.so.5
#8  0xb3df554d in ?? () from /usr/lib/libQt5DBus.so.5
#9  0xb5c6f49d in ?? () from /usr/lib/libQt5Core.so.5
#10 0xb3dcde62 in start_thread () from /usr/lib/libpthread.so.0
#11 0xb596bd96 in clone () from /usr/lib/libc.so.6

Thread 4 (Thread 0xaa6e9b40 (LWP 11431)):
#0  0xb77accd9 in __kernel_vsyscall ()
#1  0xb3dd4290 in pthread_cond_wait@@GLIBC_2.3.2 () from /usr/lib/libpthread.so.0
#2  0xae9d9a5b in ?? () from /usr/lib/xorg/modules/dri/r600_dri.so
#3  0xb3dcde62 in start_thread () from /usr/lib/libpthread.so.0
#4  0xb596bd96 in clone () from /usr/lib/libc.so.6

Thread 3 (Thread 0xab070b40 (LWP 11430)):
#0  0xb77accd9 in __kernel_vsyscall ()
#1  0xb3dd4290 in pthread_cond_wait@@GLIBC_2.3.2 () from /usr/lib/libpthread.so.0
#2  0xae9d9a5b in ?? () from /usr/lib/xorg/modules/dri/r600_dri.so
#3  0xb3dcde62 in start_thread () from /usr/lib/libpthread.so.0
#4  0xb596bd96 in clone () from /usr/lib/libc.so.6

Thread 2 (Thread 0xb08d6b40 (LWP 11429)):
#0  0xb77accd9 in __kernel_vsyscall ()
#1  0xb596144f in poll () from /usr/lib/libc.so.6
#2  0xb503194d in ?? () from /usr/lib/libxcb.so.1
#3  0xb5033cc3 in xcb_wait_for_event () from /usr/lib/libxcb.so.1
#4  0xb0a39834 in ?? () from /usr/lib/libQt5XcbQpa.so.5
#5  0xb5c6f49d in ?? () from /usr/lib/libQt5Core.so.5
#6  0xb3dcde62 in start_thread () from /usr/lib/libpthread.so.0
#7  0xb596bd96 in clone () from /usr/lib/libc.so.6

Thread 1 (Thread 0xb0d1a2c0 (LWP 11428)):
[KCrash Handler]
#6  0xb5c663ec in QMutex::tryLock(int) () from /usr/lib/libQt5Core.so.5
#7  0xb7437a94 in KisMainWindow::slotProgress(int) () from /usr/lib/libkritaui.so.17
#8  0xb6e37db2 in KoProgressUpdater::~KoProgressUpdater() () from /usr/lib/libkritawidgetutils.so.17
#9  0xb6e3814b in KoProgressUpdater::~KoProgressUpdater() () from /usr/lib/libkritawidgetutils.so.17
#10 0xb740e124 in KisDocument::clearFileProgressUpdater() () from /usr/lib/libkritaui.so.17
#11 0xb7415d50 in KisDocument::openFile() () from /usr/lib/libkritaui.so.17
#12 0xb7416618 in KisDocument::openUrlInternal(QUrl const&) () from /usr/lib/libkritaui.so.17
#13 0xb7416ab0 in KisDocument::openUrl(QUrl const&, KisDocument::OpenUrlFlags) () from /usr/lib/libkritaui.so.17
#14 0xb743708f in KisMainWindow::openDocumentInternal(QUrl const&, KisDocument*) () from /usr/lib/libkritaui.so.17
#15 0xb7405a49 in KisApplication::start(KisApplicationArguments const&) () from /usr/lib/libkritaui.so.17
#16 0x800c5c91 in main ()

Reported using DrKonqi
Comment 1 Halla Rempt 2017-11-21 10:08:12 UTC
Hi Davide, 

Sorry for the late reply. We refactored this code in the master branch, so the crash should be gone there. Though it'll always be possible to get into some weird situation when closing Krita before it's done starting up/loading an image....