Bug 340129 - KWin crashes when I change any settings option that causes decoration to be recrated
Summary: KWin crashes when I change any settings option that causes decoration to be r...
Status: RESOLVED FIXED
Alias: None
Product: kwin
Classification: Plasma
Component: aurorae (other bugs)
Version First Reported In: git master
Platform: Other Linux
: NOR crash
Target Milestone: ---
Assignee: KWin default assignee
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-10-19 18:04 UTC by Daniel Vrátil
Modified: 2015-01-07 10:39 UTC (History)
0 users

See Also:
Latest Commit:
Version Fixed/Implemented In:
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Daniel Vrátil 2014-10-19 18:04:54 UTC
I opened "Window Behavior" KCM from KRunner, checked the "Active screen follows mouse" option and clicked Apply. At this moment, KWin crashed. I can reproduce the crash every time by changing any other option that leads to Kwin::DecorationPlugin::recreateDecorations().

Reproducible: Always

Steps to Reproduce:
1. Open "Window Actions and Behavior" KCM
2. Change some of the options
3. Click apply



I'm running KWin compiled from git master (updated today) on Linux 3.15.10-201.fc20.x86_64 with integrated Intel HD Graphics 4600 GPU.
Comment 1 Thomas Lübking 2014-10-19 19:20:44 UTC
1st off:
Which decoration? Aurorae/Breeze Theme? Does it also happen with Oxygen?

Next:
Backtrace or it didn't happen ;-)

Since you know how to reproduce this (and DrKonqui is not ported...), move to VT1 before and:
$ echo 0 | sudo tee /proc/sys/kernel/yama/ptrace_scope # this allows to gdb ...
$ gdb --pid `pidof kwin` 2>&1 | tee kwin.gdb
> continue
[ move back to VT7, cause the crash, then back to VT1 ]
> bt
[ press enter until there's no more data available ]
> detach
> quit
Comment 2 Daniel Vrátil 2014-10-24 08:36:14 UTC
Happens with Breeze, and also when I was switching from Breeze to Oxygen deco, but can't reproduce with Oxygen.

Backtrace:

Thread 5 (Thread 0x7ff971e1d700 (LWP 32625)):
#0  0x0000003c700ea7cd in poll () from /lib64/libc.so.6
#1  0x0000003c73009f72 in poll (__timeout=-1, __nfds=1, __fds=0x7ff971e1cc20) at /usr/include/bits/poll2.h:46
#2  _xcb_conn_wait (c=c@entry=0x23a5310, cond=cond@entry=0x23a5350, vector=vector@entry=0x0, count=count@entry=0x0) at xcb_conn.c:414
#3  0x0000003c7300b6bf in xcb_wait_for_event (c=0x23a5310) at xcb_in.c:526
#4  0x00007ff972b44349 in QXcbEventReader::run (this=0x23af300) at qxcbconnection.cpp:1043
#5  0x0000003c7de9d3ef in QThreadPrivate::start (arg=0x23af300) at thread/qthread_unix.cpp:345
#6  0x0000003c70807f35 in start_thread () from /lib64/libpthread.so.0
#7  0x0000003c700f4c3d in clone () from /lib64/libc.so.6

Thread 4 (Thread 0x7ff96adee700 (LWP 32631)):
#0  0x0000003c700ec513 in select () from /lib64/libc.so.6
#1  0x0000003c7e0dfcb1 in qt_safe_select (nfds=nfds@entry=14, fdread=fdread@entry=0x7ff95c000a78, fdwrite=fdwrite@entry=0x7ff95c000d08, fdexcept=fdexcept@entry=0x7ff95c000f98, 
    orig_timeout=orig_timeout@entry=0x0) at kernel/qcore_unix.cpp:83
#2  0x0000003c7e0e00c3 in QEventDispatcherUNIX::select (this=this@entry=0x7ff95c0008c0, nfds=nfds@entry=14, readfds=readfds@entry=0x7ff95c000a78, writefds=writefds@entry=0x7ff95c000d08, 
    exceptfds=exceptfds@entry=0x7ff95c000f98, timeout=timeout@entry=0x0) at kernel/qeventdispatcher_unix.cpp:328
#3  0x0000003c7e0e17a2 in QEventDispatcherUNIXPrivate::doSelect (this=this@entry=0x7ff95c0008e0, flags=..., flags@entry=..., timeout=0x0) at kernel/qeventdispatcher_unix.cpp:204
#4  0x0000003c7e0e1c2b in QEventDispatcherUNIX::processEvents (this=0x7ff95c0008c0, flags=...) at kernel/qeventdispatcher_unix.cpp:615
#5  0x0000003c7e087fbb in QEventLoop::exec (this=this@entry=0x7ff96adedc80, flags=..., flags@entry=...) at kernel/qeventloop.cpp:212
#6  0x0000003c7de985e8 in QThread::exec (this=<optimized out>) at thread/qthread.cpp:511
#7  0x0000003c7de9d3ef in QThreadPrivate::start (arg=0x24ac230) at thread/qthread_unix.cpp:345
#8  0x0000003c70807f35 in start_thread () from /lib64/libpthread.so.0
#9  0x0000003c700f4c3d in clone () from /lib64/libc.so.6

Thread 3 (Thread 0x7ff963fff700 (LWP 32632)):
#0  0x0000003c700ec513 in select () from /lib64/libc.so.6
#1  0x0000003c7e0dfcb1 in qt_safe_select (nfds=nfds@entry=17, fdread=fdread@entry=0x7ff958000a78, fdwrite=fdwrite@entry=0x7ff958000d08, fdexcept=fdexcept@entry=0x7ff958000f98, 
    orig_timeout=orig_timeout@entry=0x0) at kernel/qcore_unix.cpp:83
#2  0x0000003c7e0e00c3 in QEventDispatcherUNIX::select (this=this@entry=0x7ff9580008c0, nfds=nfds@entry=17, readfds=readfds@entry=0x7ff958000a78, writefds=writefds@entry=0x7ff958000d08, 
    exceptfds=exceptfds@entry=0x7ff958000f98, timeout=timeout@entry=0x0) at kernel/qeventdispatcher_unix.cpp:328
#3  0x0000003c7e0e17a2 in QEventDispatcherUNIXPrivate::doSelect (this=this@entry=0x7ff9580008e0, flags=..., flags@entry=..., timeout=0x0) at kernel/qeventdispatcher_unix.cpp:204
#4  0x0000003c7e0e1c2b in QEventDispatcherUNIX::processEvents (this=0x7ff9580008c0, flags=...) at kernel/qeventdispatcher_unix.cpp:615
#5  0x0000003c7e087fbb in QEventLoop::exec (this=this@entry=0x7ff963ffec80, flags=..., flags@entry=...) at kernel/qeventloop.cpp:212
#6  0x0000003c7de985e8 in QThread::exec (this=<optimized out>) at thread/qthread.cpp:511
#7  0x0000003c7de9d3ef in QThreadPrivate::start (arg=0x2b99dc0) at thread/qthread_unix.cpp:345
#8  0x0000003c70807f35 in start_thread () from /lib64/libpthread.so.0
#9  0x0000003c700f4c3d in clone () from /lib64/libc.so.6

Thread 2 (Thread 0x7ff961c81700 (LWP 32633)):
#0  0x0000003c7080bcf0 in pthread_cond_wait@@GLIBC_2.3.2 () from /lib64/libpthread.so.0
#1  0x0000003c81b7b12b in QTWTF::TCMalloc_PageHeap::scavengerThread (this=0x3c81e65ec0 <QTWTF::pageheap_memory>) at ../3rdparty/javascriptcore/JavaScriptCore/wtf/FastMalloc.cpp:2359
#2  0x0000003c81b7b159 in QTWTF::TCMalloc_PageHeap::runScavengerThread (context=<optimized out>) at ../3rdparty/javascriptcore/JavaScriptCore/wtf/FastMalloc.cpp:1464
#3  0x0000003c70807f35 in start_thread () from /lib64/libpthread.so.0
#4  0x0000003c700f4c3d in clone () from /lib64/libc.so.6

Thread 1 (Thread 0x7ff9792f5940 (LWP 32624)):
#0  QOpenGLContext::shareGroup (this=this@entry=0x0) at kernel/qopenglcontext.cpp:950
#1  0x0000003c815b1920 in value<QOpenGLFunctionsPrivateEx> (context=0x0, this=0x3c81918f50 <(anonymous namespace)::Q_QGS_qt_gl_functions_resource::innerFunction()::holder>)
    at ../../src/gui/kernel/qopenglcontext_p.h:173
#2  qt_gl_functions (context=context@entry=0x0) at opengl/qopenglfunctions.cpp:203
#3  0x0000003c815bd66f in (anonymous namespace)::Resolver<QOpenGLFunctionsPrivate, void (*)(int, unsigned int const*), 3, void>::operator()<int, unsigned int const*> (this=this@entry=0x7fffa3a08030, 
    p1=p1@entry=1, p2=p2@entry=0x33e0488) at opengl/qopenglfunctions.cpp:2294
#4  0x0000003c815bd9a2 in qopenglfResolveDeleteRenderbuffers (n=1, renderbuffers=0x33e0488) at opengl/qopenglfunctions.cpp:2752
#5  0x0000003c85741693 in glDeleteRenderbuffers (renderbuffers=0x33e0488, n=1, this=0x33e0468) at /usr/include/qt5/QtGui/qopenglfunctions.h:1325
#6  QSGDefaultDepthStencilBuffer::free (this=this@entry=0x33e0460) at /usr/src/debug/qtdeclarative-opensource-src-5.3.1/src/quick/scenegraph/util/qsgdepthstencilbuffer.cpp:153
#7  0x0000003c85741cb3 in QSGDefaultDepthStencilBuffer::~QSGDefaultDepthStencilBuffer (this=0x33e0460, __in_chrg=<optimized out>)
    at /usr/src/debug/qtdeclarative-opensource-src-5.3.1/src/quick/scenegraph/util/qsgdepthstencilbuffer.cpp:147
#8  0x0000003c85741ce9 in QSGDefaultDepthStencilBuffer::~QSGDefaultDepthStencilBuffer (this=0x33e0460, __in_chrg=<optimized out>)
    at /usr/src/debug/qtdeclarative-opensource-src-5.3.1/src/quick/scenegraph/util/qsgdepthstencilbuffer.cpp:148
#9  0x0000003c8586f59e in destroy (this=0x33e12f0) at /usr/include/qt5/QtCore/qsharedpointer_impl.h:158
#10 deref (d=0x33e12f0) at /usr/include/qt5/QtCore/qsharedpointer_impl.h:449
#11 deref (this=<optimized out>) at /usr/include/qt5/QtCore/qsharedpointer_impl.h:444
#12 ~QSharedPointer (this=0x3aae818, __in_chrg=<optimized out>) at /usr/include/qt5/QtCore/qsharedpointer_impl.h:312
#13 QQuickShaderEffectTexture::~QQuickShaderEffectTexture (this=0x3aae7b0, __in_chrg=<optimized out>) at /usr/src/debug/qtdeclarative-opensource-src-5.3.1/src/quick/items/qquickshadereffectsource.cpp:159
#14 0x0000003c8586f5a9 in QQuickShaderEffectTexture::~QQuickShaderEffectTexture (this=0x3aae7b0, __in_chrg=<optimized out>)
    at /usr/src/debug/qtdeclarative-opensource-src-5.3.1/src/quick/items/qquickshadereffectsource.cpp:162
#15 0x0000003c7e0bb358 in QObject::event (this=0x3aae7b0, e=<optimized out>) at kernel/qobject.cpp:1232
#16 0x0000003c82540f8c in QApplicationPrivate::notify_helper (this=this@entry=0x239c650, receiver=receiver@entry=0x3aae7b0, e=e@entry=0x2484db0) at kernel/qapplication.cpp:3522
#17 0x0000003c82546396 in QApplication::notify (this=0x7fffa3a09600, receiver=0x3aae7b0, e=0x2484db0) at kernel/qapplication.cpp:3305
#18 0x00007ff97eebb77c in KWin::Application::notify (this=0x7fffa3a09600, o=0x3aae7b0, e=0x2484db0) at /home/dvratil/KDE/kde/workspace/kwin/main.cpp:228
#19 0x0000003c7e08a195 in QCoreApplication::notifyInternal (this=0x7fffa3a09600, receiver=0x3aae7b0, event=event@entry=0x2484db0) at kernel/qcoreapplication.cpp:935
#20 0x0000003c7e08c117 in sendEvent (event=0x2484db0, receiver=<optimized out>) at kernel/qcoreapplication.h:237
#21 QCoreApplicationPrivate::sendPostedEvents (receiver=receiver@entry=0x0, event_type=event_type@entry=52, data=0x2387470) at kernel/qcoreapplication.cpp:1539
#22 0x0000003c7e08c728 in QCoreApplication::sendPostedEvents (receiver=receiver@entry=0x0, event_type=event_type@entry=52) at kernel/qcoreapplication.cpp:1397
#23 0x0000003c8578c894 in QQuickWindow::~QQuickWindow (this=0x2c85460, __in_chrg=<optimized out>) at /usr/src/debug/qtdeclarative-opensource-src-5.3.1/src/quick/items/qquickwindow.cpp:1096
#24 0x0000003c8578c989 in QQuickWindow::~QQuickWindow (this=0x2c85460, __in_chrg=<optimized out>) at /usr/src/debug/qtdeclarative-opensource-src-5.3.1/src/quick/items/qquickwindow.cpp:1102
#25 0x00007ff97ec00343 in QScopedPointerDeleter<QWindow>::cleanup (pointer=0x2c85460) at /usr/include/qt5/QtCore/qscopedpointer.h:62
#26 0x00007ff97ebffa73 in QScopedPointer<QWindow, QScopedPointerDeleter<QWindow> >::~QScopedPointer (this=0x2794f50, __in_chrg=<optimized out>) at /usr/include/qt5/QtCore/qscopedpointer.h:109
#27 0x00007ff97ebff89e in KDecorationPrivate::~KDecorationPrivate (this=0x2794f30, __in_chrg=<optimized out>) at /home/dvratil/KDE/kde/workspace/kwin/libkdecorations/kdecoration.cpp:56
#28 0x00007ff97ebfbc53 in KDecoration::~KDecoration (this=0x2639370, __in_chrg=<optimized out>) at /home/dvratil/KDE/kde/workspace/kwin/libkdecorations/kdecoration.cpp:87
#29 0x00007ff9700c01bd in Aurorae::AuroraeClient::~AuroraeClient() () from /usr/lib64/qt5/plugins/kwin/kdecorations/kwin3_aurorae.so
#30 0x00007ff97ee8d01b in KWin::Client::destroyDecoration (this=0x263e880) at /home/dvratil/KDE/kde/workspace/kwin/client.cpp:579
#31 0x00007ff97ee8c62b in KWin::Client::updateDecoration (this=0x263e880, check_workspace_pos=true, force=true) at /home/dvratil/KDE/kde/workspace/kwin/client.cpp:512
#32 0x00007ff97eec6c66 in KWin::DecorationPlugin::__lambda23::operator() (__closure=0x39668c0, c=0x263e880) at /home/dvratil/KDE/kde/workspace/kwin/decorations.cpp:173
#33 0x00007ff97eec6ea5 in std::_Function_handler<void(KWin::Client*), KWin::DecorationPlugin::recreateDecorations()::__lambda23>::_M_invoke(const std::_Any_data &, KWin::Client *) (__functor=..., 
    __args#0=0x263e880) at /usr/include/c++/4.8.3/functional:2071
#34 0x00007ff97eec769d in std::function<void (KWin::Client*)>::operator()(KWin::Client*) const (this=0x7fffa3a08770, __args#0=0x263e880) at /usr/include/c++/4.8.3/functional:2471
#35 0x00007ff97eec74fc in std::for_each<QList<KWin::Client*>::const_iterator, std::function<void (KWin::Client*)> >(QList<KWin::Client*>::const_iterator, QList<KWin::Client*>::const_iterator, std::function<void (KWin::Client*)>) (__first=..., __last=..., __f=...) at /usr/include/c++/4.8.3/bits/stl_algo.h:4417
#36 0x00007ff97eec7384 in KWin::Workspace::forEachClient(std::function<void (KWin::Client*)>) (this=0x2482dc0, func=...) at /home/dvratil/KDE/kde/workspace/kwin/workspace.h:704
#37 0x00007ff97eec6cdc in KWin::DecorationPlugin::recreateDecorations (this=0x24538f0) at /home/dvratil/KDE/kde/workspace/kwin/decorations.cpp:174
#38 0x00007ff97ee8874b in QtPrivate::FunctorCall<QtPrivate::IndexesList<>, QtPrivate::List<>, void, void (KWin::DecorationPlugin::*)()>::call(void (KWin::DecorationPlugin::*)(), KWin::DecorationPlugin*, void**) (f=(void (KWin::DecorationPlugin::*)(KWin::DecorationPlugin * const)) 0x7ff97eec6c9e <KWin::DecorationPlugin::recreateDecorations()>, o=0x24538f0, arg=0x7fffa3a08a00)
    at /usr/include/qt5/QtCore/qobjectdefs_impl.h:508
#39 0x00007ff97ee873e4 in QtPrivate::FunctionPointer<void (KWin::DecorationPlugin::*)()>::call<QtPrivate::List<>, void>(void (KWin::DecorationPlugin::*)(), KWin::DecorationPlugin*, void**) (
    f=(void (KWin::DecorationPlugin::*)(KWin::DecorationPlugin * const)) 0x7ff97eec6c9e <KWin::DecorationPlugin::recreateDecorations()>, o=0x24538f0, arg=0x7fffa3a08a00)
    at /usr/include/qt5/QtCore/qobjectdefs_impl.h:527
#40 0x00007ff97ee86055 in QtPrivate::QSlotObject<void (KWin::DecorationPlugin::*)(), QtPrivate::List<>, void>::impl(int, QtPrivate::QSlotObjectBase*, QObject*, void**, bool*) (which=1, this_=0x2497270, 
    r=0x24538f0, a=0x7fffa3a08a00, ret=0x0) at /usr/include/qt5/QtCore/qobject_impl.h:151
#41 0x0000003c7e0ba0db in call (a=0x7fffa3a08a00, r=0x24538f0, this=0x2497270) at ../../src/corelib/kernel/qobject_impl.h:132
#42 QMetaObject::activate (sender=0x24975c0, signalOffset=<optimized out>, local_signal_index=<optimized out>, argv=0x0) at kernel/qobject.cpp:3666
#43 0x00007ff97ec10611 in KDecorationFactory::recreateDecorations (this=0x24975c0) at /home/dvratil/KDE/build/kde/workspace/kwin/libkdecorations/moc_kdecorationfactory.cpp:125
#44 0x00007ff9700bfcbc in Aurorae::AuroraeFactory::updateConfiguration() () from /usr/lib64/qt5/plugins/kwin/kdecorations/kwin3_aurorae.so
#45 0x0000003c7e0ba0db in call (a=0x7fffa3a08c60, r=0x24975c0, this=0x2582d50) at ../../src/corelib/kernel/qobject_impl.h:132
#46 QMetaObject::activate (sender=0x247ddf0, signalOffset=<optimized out>, local_signal_index=<optimized out>, argv=0x0) at kernel/qobject.cpp:3666
#47 0x00007ff97ec0f58b in KDecorationOptions::configChanged (this=0x247ddf0) at /home/dvratil/KDE/build/kde/workspace/kwin/libkdecorations/moc_kdecoration.cpp:333
#48 0x00007ff97eebfbde in KWin::Options::updateSettings (this=0x247ddf0) at /home/dvratil/KDE/kde/workspace/kwin/options.cpp:810
#49 0x00007ff97ee75aaa in KWin::Workspace::slotReconfigure (this=0x2482dc0) at /home/dvratil/KDE/kde/workspace/kwin/workspace.cpp:780
#50 0x00007ff97efef1f3 in KWin::Workspace::qt_static_metacall (_o=0x2482dc0, _c=QMetaObject::InvokeMetaMethod, _id=69, _a=0x7fffa3a08f80) at /home/dvratil/KDE/build/kde/workspace/kwin/moc_workspace.cpp:472
#51 0x0000003c7e0ba5de in QMetaObject::activate (sender=sender@entry=0x2482ed0, signalOffset=<optimized out>, local_signal_index=local_signal_index@entry=0, argv=argv@entry=0x0) at kernel/qobject.cpp:3680
#52 0x0000003c7e0baa97 in QMetaObject::activate (sender=sender@entry=0x2482ed0, m=m@entry=0x3c7e4cd7c0 <QTimer::staticMetaObject>, local_signal_index=local_signal_index@entry=0, argv=argv@entry=0x0)
    at kernel/qobject.cpp:3546
#53 0x0000003c7e13be60 in QTimer::timeout (this=this@entry=0x2482ed0) at .moc/moc_qtimer.cpp:191
#54 0x0000003c7e0c7c32 in QTimer::timerEvent (this=0x2482ed0, e=<optimized out>) at kernel/qtimer.cpp:255
#55 0x0000003c7e0bb10c in QObject::event (this=0x2482ed0, e=<optimized out>) at kernel/qobject.cpp:1222
#56 0x0000003c82540f8c in QApplicationPrivate::notify_helper (this=this@entry=0x239c650, receiver=receiver@entry=0x2482ed0, e=e@entry=0x7fffa3a093f0) at kernel/qapplication.cpp:3522
#57 0x0000003c82546396 in QApplication::notify (this=0x7fffa3a09600, receiver=0x2482ed0, e=0x7fffa3a093f0) at kernel/qapplication.cpp:3305
#58 0x00007ff97eebb77c in KWin::Application::notify (this=0x7fffa3a09600, o=0x2482ed0, e=0x7fffa3a093f0) at /home/dvratil/KDE/kde/workspace/kwin/main.cpp:228
#59 0x0000003c7e08a195 in QCoreApplication::notifyInternal (this=0x7fffa3a09600, receiver=0x2482ed0, event=event@entry=0x7fffa3a093f0) at kernel/qcoreapplication.cpp:935
#60 0x0000003c7e0e350d in sendEvent (event=0x7fffa3a093f0, receiver=<optimized out>) at ../../src/corelib/kernel/qcoreapplication.h:237
#61 QTimerInfoList::activateTimers (this=0x23efa08) at kernel/qtimerinfo_unix.cpp:643
#62 0x0000003c7e0e0ed0 in QEventDispatcherUNIX::activateTimers (this=this@entry=0x23d1980) at kernel/qeventdispatcher_unix.cpp:557
#63 0x0000003c7e0e1cc8 in QEventDispatcherUNIX::processEvents (this=0x23d1980, flags=flags@entry=...) at kernel/qeventdispatcher_unix.cpp:619
#64 0x00007ff972b9639d in QUnixEventDispatcherQPA::processEvents (this=<optimized out>, flags=...) at eventdispatchers/qunixeventdispatcher.cpp:70
#65 0x0000003c7e087fbb in QEventLoop::exec (this=this@entry=0x7fffa3a09570, flags=..., flags@entry=...) at kernel/qeventloop.cpp:212
#66 0x0000003c7e08f996 in QCoreApplication::exec () at kernel/qcoreapplication.cpp:1188
#67 0x00007ff97f2c0e8c in kdemain (argc=2, argv=0x7fffa3a09848) at /home/dvratil/KDE/kde/workspace/kwin/main_x11.cpp:294
#68 0x0000000000400c12 in main (argc=2, argv=0x7fffa3a09848) at /home/dvratil/KDE/build/kde/workspace/kwin/kwin_x11_dummy.cpp:3
Comment 3 Martin Flöser 2014-10-24 08:47:08 UTC
see https://community.kde.org/Plasma/5.1_Errata :
> Aurorae window decoration themes might crash the window manager, upstream bug: https://bugreports.qt-project.org/browse/QTBUG-39336
Comment 4 Martin Flöser 2015-01-07 10:39:47 UTC
aurorae crashes on kwin reconfiguration/restart should be fixed either with kdecoration2 and/or Qt 5.4