Bug 397577 - Plasma crashing after window resizing with Meta+R shortcut and pressing Enter on Wayland
Summary: Plasma crashing after window resizing with Meta+R shortcut and pressing Enter...
Status: RESOLVED FIXED
Alias: None
Product: kwin
Classification: Plasma
Component: wayland-generic (show other bugs)
Version: git master
Platform: Other Linux
: NOR crash
Target Milestone: ---
Assignee: KWin default assignee
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2018-08-18 10:50 UTC by Alexander Mentyu
Modified: 2018-11-13 08:35 UTC (History)
3 users (show)

See Also:
Latest Commit:
Version Fixed In: 5.14.4
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Alexander Mentyu 2018-08-18 10:50:16 UTC
Steps:
1. Start Wayland session.
2. Start some Wayland window - tested with Dolphin.
3. Invoke resizing by Meta+R shortcut.
4. Change Dolphin window size.
5. Press Enter to finish resize action.

Actual:
Plasma crashing

Can you please help me of how to get a backtrace of this crash?

Distribution: KDE neon Developer Edition
Kernel: 4.15.0-29-generic
Plasma: 5.13.80
Apps: 18.11.70
Qt: 5.11.1
Frameworks: 5.48.0
Graphics:  Card-1: Intel 
driver: i915 v: kernel bus ID: 00:02.0 chip ID: 8086:5917 
Card-2: NVIDIA GM108M [GeForce 940MX] 
driver: nouveau v: kernel bus ID: 01:00.0 chip ID: 10de:134d 
Display: wayland server: X.Org 1.19.6 
driver: modesetting,nouveau 
unloaded: fbdev,vesa alternate: nvidia compositor: kwin wayland 
resolution: 1920x1080~57Hz 
OpenGL: renderer: Mesa DRI Intel UHD Graphics 620 (Kabylake GT2) 
v:4.5 Mesa 18.0.5 compat-v:3.0 direct render: Yes
Comment 1 Martin Flöser 2018-08-18 14:57:12 UTC
Best is to ssh in from another system and attach gdb to KWin.
Comment 2 Alexander Mentyu 2018-08-24 13:30:02 UTC
Thread 14 (Thread 0x7fb221ffb700 (LWP 7060)):
#0  pthread_cond_wait@@GLIBC_2.3.2 () at ../sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S:185
#1  0x00007fb29141a5cb in QWaitConditionPrivate::wait (time=18446744073709551615, this=0x5ad9380) at thread/qwaitcondition_unix.cpp:143
#2  QWaitCondition::wait (this=<optimized out>, mutex=0x2532ca0, time=18446744073709551615) at thread/qwaitcondition_unix.cpp:215
#3  0x00007fb25d59b78f in ThreadWeaver::Weaver::takeFirstAvailableJobOrSuspendOrWait(ThreadWeaver::Thread*, bool, bool, bool) ()
   from /usr/lib/x86_64-linux-gnu/libKF5ThreadWeaver.so.5
#4  0x00007fb25d59f868 in ?? () from /usr/lib/x86_64-linux-gnu/libKF5ThreadWeaver.so.5
#5  0x00007fb25d59a9ed in ThreadWeaver::Weaver::applyForWork(ThreadWeaver::Thread*, bool) ()
   from /usr/lib/x86_64-linux-gnu/libKF5ThreadWeaver.so.5
#6  0x00007fb25d59f8c2 in ?? () from /usr/lib/x86_64-linux-gnu/libKF5ThreadWeaver.so.5
#7  0x00007fb25d59a9ed in ThreadWeaver::Weaver::applyForWork(ThreadWeaver::Thread*, bool) ()
   from /usr/lib/x86_64-linux-gnu/libKF5ThreadWeaver.so.5
#8  0x00007fb25d59f8c2 in ?? () from /usr/lib/x86_64-linux-gnu/libKF5ThreadWeaver.so.5
#9  0x00007fb25d59a9ed in ThreadWeaver::Weaver::applyForWork(ThreadWeaver::Thread*, bool) ()
   from /usr/lib/x86_64-linux-gnu/libKF5ThreadWeaver.so.5
#10 0x00007fb25d59f8c2 in ?? () from /usr/lib/x86_64-linux-gnu/libKF5ThreadWeaver.so.5
#11 0x00007fb25d59a9ed in ThreadWeaver::Weaver::applyForWork(ThreadWeaver::Thread*, bool) ()
   from /usr/lib/x86_64-linux-gnu/libKF5ThreadWeaver.so.5
#12 0x00007fb25d59f8c2 in ?? () from /usr/lib/x86_64-linux-gnu/libKF5ThreadWeaver.so.5
#13 0x00007fb25d59a9ed in ThreadWeaver::Weaver::applyForWork(ThreadWeaver::Thread*, bool) ()
---Type <return> to continue, or q <return> to quit---
   from /usr/lib/x86_64-linux-gnu/libKF5ThreadWeaver.so.5
#14 0x00007fb25d59f8c2 in ?? () from /usr/lib/x86_64-linux-gnu/libKF5ThreadWeaver.so.5
#15 0x00007fb25d59a9ed in ThreadWeaver::Weaver::applyForWork(ThreadWeaver::Thread*, bool) ()
   from /usr/lib/x86_64-linux-gnu/libKF5ThreadWeaver.so.5
#16 0x00007fb25d59f8c2 in ?? () from /usr/lib/x86_64-linux-gnu/libKF5ThreadWeaver.so.5
#17 0x00007fb25d59a9ed in ThreadWeaver::Weaver::applyForWork(ThreadWeaver::Thread*, bool) ()
   from /usr/lib/x86_64-linux-gnu/libKF5ThreadWeaver.so.5
#18 0x00007fb25d59f8c2 in ?? () from /usr/lib/x86_64-linux-gnu/libKF5ThreadWeaver.so.5
#19 0x00007fb25d59a9ed in ThreadWeaver::Weaver::applyForWork(ThreadWeaver::Thread*, bool) ()
   from /usr/lib/x86_64-linux-gnu/libKF5ThreadWeaver.so.5
#20 0x00007fb25d59f8c2 in ?? () from /usr/lib/x86_64-linux-gnu/libKF5ThreadWeaver.so.5
#21 0x00007fb25d59a9ed in ThreadWeaver::Weaver::applyForWork(ThreadWeaver::Thread*, bool) ()
   from /usr/lib/x86_64-linux-gnu/libKF5ThreadWeaver.so.5
#22 0x00007fb25d59d3e0 in ThreadWeaver::Thread::run() () from /usr/lib/x86_64-linux-gnu/libKF5ThreadWeaver.so.5
#23 0x00007fb291419727 in QThreadPrivate::start (arg=0x7fb210003190) at thread/qthread_unix.cpp:367
#24 0x00007fb28e2206ba in start_thread (arg=0x7fb221ffb700) at pthread_create.c:333
#25 0x00007fb290d2641d in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:109

Thread 13 (Thread 0x7fb2227fc700 (LWP 7059)):
#0  pthread_cond_wait@@GLIBC_2.3.2 () at ../sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S:185
#1  0x00007fb29141a5cb in QWaitConditionPrivate::wait (time=18446744073709551615, this=0x5ad9380) at thread/qwaitcondition_unix.cpp:143
#2  QWaitCondition::wait (this=<optimized out>, mutex=0x2532ca0, time=18446744073709551615) at thread/qwaitcondition_unix.cpp:215
#3  0x00007fb25d59b78f in ThreadWeaver::Weaver::takeFirstAvailableJobOrSuspendOrWait(ThreadWeaver::Thread*, bool, bool, bool) ()
   from /usr/lib/x86_64-linux-gnu/libKF5ThreadWeaver.so.5
#4  0x00007fb25d59f868 in ?? () from /usr/lib/x86_64-linux-gnu/libKF5ThreadWeaver.so.5
#5  0x00007fb25d59a9ed in ThreadWeaver::Weaver::applyForWork(ThreadWeaver::Thread*, bool) ()
   from /usr/lib/x86_64-linux-gnu/libKF5ThreadWeaver.so.5
#6  0x00007fb25d59f8c2 in ?? () from /usr/lib/x86_64-linux-gnu/libKF5ThreadWeaver.so.5
#7  0x00007fb25d59a9ed in ThreadWeaver::Weaver::applyForWork(ThreadWeaver::Thread*, bool) ()
   from /usr/lib/x86_64-linux-gnu/libKF5ThreadWeaver.so.5
#8  0x00007fb25d59f8c2 in ?? () from /usr/lib/x86_64-linux-gnu/libKF5ThreadWeaver.so.5
#9  0x00007fb25d59a9ed in ThreadWeaver::Weaver::applyForWork(ThreadWeaver::Thread*, bool) ()
   from /usr/lib/x86_64-linux-gnu/libKF5ThreadWeaver.so.5>
Comment 3 Patrick Silva 2018-08-24 20:03:37 UTC
I do not use meta+r shortcut but I can reproduce the crash on neon dev unstable.
Is this backtrace helpful?

aThread 9 (Thread 3764.3789):
#0  pthread_cond_wait@@GLIBC_2.3.2 () at ../sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S:185
#1  0x00007f57edb87de4 in QTWTF::TCMalloc_PageHeap::scavengerThread (
    this=0x7f57ede6dee0 <QTWTF::pageheap_memory>)
    at ../3rdparty/javascriptcore/JavaScriptCore/wtf/FastMalloc.cpp:2359
#2  0x00007f57edb87e29 in QTWTF::TCMalloc_PageHeap::runScavengerThread (context=<optimized out>)
    at ../3rdparty/javascriptcore/JavaScriptCore/wtf/FastMalloc.cpp:1464
#3  0x00007f57f01916ba in start_thread (arg=0x7f57a9985700) at pthread_create.c:333
#4  0x00007f57ee4e841d in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:109

Thread 8 (Thread 3764.3787):
#0  pthread_cond_wait@@GLIBC_2.3.2 () at ../sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S:185
#1  0x00007f57eedfe5cb in QWaitConditionPrivate::wait (time=18446744073709551615, this=0x2c8b650)
    at thread/qwaitcondition_unix.cpp:143
#2  QWaitCondition::wait (this=this@entry=0x2c8b420, mutex=mutex@entry=0x2c8b418, 
    time=time@entry=18446744073709551615) at thread/qwaitcondition_unix.cpp:215
#3  0x00007f57b2d8603a in FileInfoThread::run (this=0x2c8b408) at fileinfothread.cpp:227
#4  0x00007f57eedfd727 in QThreadPrivate::start (arg=0x2c8b408) at thread/qthread_unix.cpp:367
#5  0x00007f57f01916ba in start_thread (arg=0x7f57aa987700) at pthread_create.c:333
#6  0x00007f57ee4e841d in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:109

Thread 7 (Thread 3764.3786):
#0  syscall () at ../sysdeps/unix/sysv/linux/x86_64/syscall.S:38
#1  0x00007f57eedf0fa4 in QtLinuxFutex::_q_futex (val3=0, addr2=0x0, val2=0, val=<optimized out>, op=0, 
    addr=<optimized out>) at thread/qfutex_p.h:92
#2  QtLinuxFutex::futexWait<QBasicAtomicInteger<unsigned int> > (expectedValue=<optimized out>, futex=...)
---Type <return> to continue, or q <return> to quit---
    at thread/qfutex_p.h:107
#3  futexSemaphoreTryAcquire_loop<false> (timeout=-1, nn=8589934593, curValue=<optimized out>, u=...)
    at thread/qsemaphore.cpp:221
#4  futexSemaphoreTryAcquire<false> (timeout=-1, n=1, u=...) at thread/qsemaphore.cpp:264
#5  QSemaphore::acquire (this=this@entry=0x2cd7858, n=n@entry=1) at thread/qsemaphore.cpp:328
#6  0x00007f57d554de2a in QtVirtualKeyboard::HunspellWorker::run (this=0x2cd7840) at hunspellworker.cpp:293
#7  0x00007f57eedfd727 in QThreadPrivate::start (arg=0x2cd7840) at thread/qthread_unix.cpp:367
#8  0x00007f57f01916ba in start_thread (arg=0x7f57b2d79700) at pthread_create.c:333
#9  0x00007f57ee4e841d in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:109

Thread 6 (Thread 3764.3785):
#0  0x00007f57ee4dc74d in poll () at ../sysdeps/unix/syscall-template.S:84
#1  0x00007f57e575c38c in g_main_context_poll (priority=2147483647, n_fds=1, fds=0x7f57b8002c70, 
    timeout=<optimized out>, context=0x7f57b8000990)
    at /build/glib2.0-b4FPyK/glib2.0-2.48.2/./glib/gmain.c:4135
#2  g_main_context_iterate (context=context@entry=0x7f57b8000990, block=block@entry=1, 
    dispatch=dispatch@entry=1, self=<optimized out>)
    at /build/glib2.0-b4FPyK/glib2.0-2.48.2/./glib/gmain.c:3835
#3  0x00007f57e575c49c in g_main_context_iteration (context=0x7f57b8000990, may_block=may_block@entry=1)
    at /build/glib2.0-b4FPyK/glib2.0-2.48.2/./glib/gmain.c:3901
#4  0x00007f57ef01609f in QEventDispatcherGlib::processEvents (this=0x7f57b80008c0, flags=...)
    at kernel/qeventdispatcher_glib.cpp:423
#5  0x00007f57eefbd5ba in QEventLoop::exec (this=this@entry=0x7f57c4b14c50, flags=..., flags@entry=...)
    at kernel/qeventloop.cpp:214
#6  0x00007f57eedf25e4 in QThread::exec (this=this@entry=0x2c0cf10) at thread/qthread.cpp:525
#7  0x00007f57e97a5195 in QQmlThreadPrivate::run (this=0x2c0cf10) at qml/ftw/qqmlthread.cpp:148
#8  0x00007f57eedfd727 in QThreadPrivate::start (arg=0x2c0cf10) at thread/qthread_unix.cpp:367
---Type <return> to continue, or q <return> to quit---
#9  0x00007f57f01916ba in start_thread (arg=0x7f57c4b15700) at pthread_create.c:333
#10 0x00007f57ee4e841d in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:109

Thread 5 (Thread 3764.3782):
#0  0x00007f57ee4dc74d in poll () at ../sysdeps/unix/syscall-template.S:84
#1  0x00007f57e575c38c in g_main_context_poll (priority=2147483647, n_fds=1, fds=0x7f57b4003070, 
    timeout=<optimized out>, context=0x7f57b4000990)
    at /build/glib2.0-b4FPyK/glib2.0-2.48.2/./glib/gmain.c:4135
#2  g_main_context_iterate (context=context@entry=0x7f57b4000990, block=block@entry=1, 
    dispatch=dispatch@entry=1, self=<optimized out>)
    at /build/glib2.0-b4FPyK/glib2.0-2.48.2/./glib/gmain.c:3835
#3  0x00007f57e575c49c in g_main_context_iteration (context=0x7f57b4000990, may_block=may_block@entry=1)
    at /build/glib2.0-b4FPyK/glib2.0-2.48.2/./glib/gmain.c:3901
#4  0x00007f57ef0160bb in QEventDispatcherGlib::processEvents (this=0x7f57b40008c0, flags=...)
    at kernel/qeventdispatcher_glib.cpp:425
#5  0x00007f57eefbd5ba in QEventLoop::exec (this=this@entry=0x7f57c6209c50, flags=..., flags@entry=...)
    at kernel/qeventloop.cpp:214
#6  0x00007f57eedf25e4 in QThread::exec (this=this@entry=0x2b46d20) at thread/qthread.cpp:525
#7  0x00007f57e97a5195 in QQmlThreadPrivate::run (this=0x2b46d20) at qml/ftw/qqmlthread.cpp:148
#8  0x00007f57eedfd727 in QThreadPrivate::start (arg=0x2b46d20) at thread/qthread_unix.cpp:367
#9  0x00007f57f01916ba in start_thread (arg=0x7f57c620a700) at pthread_create.c:333
#10 0x00007f57ee4e841d in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:109

Thread 4 (Thread 3764.3767):
#0  syscall () at ../sysdeps/unix/sysv/linux/x86_64/syscall.S:38
#1  0x00007f57eedee355 in QtLinuxFutex::_q_futex (val3=0, addr2=0x0, val2=0, val=3, op=0, addr=<optimized out>)
    at thread/qfutex_p.h:92
---Type <return> to continue, or q <return> to quit---
#2  QtLinuxFutex::futexWait<QBasicAtomicPointer<QMutexData> > (expectedValue=<optimized out>, futex=...)
    at thread/qfutex_p.h:107
#3  lockInternal_helper<false> (timeout=-1, elapsedTimer=0x0, d_ptr=...) at thread/qmutex_linux.cpp:145
#4  QBasicMutex::lockInternal (this=0x230ee18) at thread/qmutex_linux.cpp:162
#5  0x00007f57eedee412 in QBasicMutex::lock (this=0x230ee18) at thread/qmutex.h:79
#6  QRecursiveMutexPrivate::lock (timeout=-1, this=0x230ee00) at thread/qmutex.cpp:708
#7  QMutex::lock (this=this@entry=0x2360b18) at thread/qmutex.cpp:227
#8  0x00007f57f13cf224 in QMutexLocker::QMutexLocker (m=0x2360b18, this=<synthetic pointer>)
    at /usr/include/x86_64-linux-gnu/qt5/QtCore/qmutex.h:206
#9  KWin::LibInput::Connection::handleEvent (this=0x2360ad0) at /workspace/build/libinput/connection.cpp:232
#10 0x00007f57eefec2a6 in QtPrivate::QSlotObjectBase::call (a=0x7f57cf5c17f0, r=0x2360ad0, 
    this=<optimized out>) at ../../include/QtCore/../../src/corelib/kernel/qobjectdefs_impl.h:376
#11 QMetaObject::activate (sender=sender@entry=0x7f57c0002e00, signalOffset=<optimized out>, 
    local_signal_index=local_signal_index@entry=0, argv=argv@entry=0x7f57cf5c17f0) at kernel/qobject.cpp:3754
#12 0x00007f57eefec887 in QMetaObject::activate (sender=sender@entry=0x7f57c0002e00, 
    m=m@entry=0x7f57ef440c60 <QSocketNotifier::staticMetaObject>, 
    local_signal_index=local_signal_index@entry=0, argv=argv@entry=0x7f57cf5c17f0) at kernel/qobject.cpp:3633
#13 0x00007f57eeff8538 in QSocketNotifier::activated (this=this@entry=0x7f57c0002e00, _t1=20, _t2=...)
    at .moc/moc_qsocketnotifier.cpp:136
#14 0x00007f57eeff88eb in QSocketNotifier::event (this=0x7f57c0002e00, e=<optimized out>)
    at kernel/qsocketnotifier.cpp:266
#15 0x00007f57ef5a239c in QApplicationPrivate::notify_helper(QObject*, QEvent*) ()
   from target:/usr/lib/x86_64-linux-gnu/libQt5Widgets.so.5
#16 0x00007f57ef5a9ab0 in QApplication::notify(QObject*, QEvent*) ()
   from target:/usr/lib/x86_64-linux-gnu/libQt5Widgets.so.5
#17 0x00007f57eefbf228 in QCoreApplication::notifyInternal2 (receiver=0x7f57c0002e00, 
    event=event@entry=0x7f57cf5c1a50) at kernel/qcoreapplication.cpp:1048
---Type <return> to continue, or q <return> to quit---
#18 0x00007f57ef016d1d in QCoreApplication::sendEvent (event=0x7f57cf5c1a50, receiver=<optimized out>)
    at ../../include/QtCore/../../src/corelib/kernel/qcoreapplication.h:234
#19 socketNotifierSourceDispatch (source=0x7f57c0002a00) at kernel/qeventdispatcher_glib.cpp:106
#20 0x00007f57e575c197 in g_main_dispatch (context=0x7f57c0000990)
    at /build/glib2.0-b4FPyK/glib2.0-2.48.2/./glib/gmain.c:3154
#21 g_main_context_dispatch (context=context@entry=0x7f57c0000990)
    at /build/glib2.0-b4FPyK/glib2.0-2.48.2/./glib/gmain.c:3769
#22 0x00007f57e575c3f0 in g_main_context_iterate (context=context@entry=0x7f57c0000990, block=block@entry=1, 
    dispatch=dispatch@entry=1, self=<optimized out>)
    at /build/glib2.0-b4FPyK/glib2.0-2.48.2/./glib/gmain.c:3840
#23 0x00007f57e575c49c in g_main_context_iteration (context=0x7f57c0000990, may_block=may_block@entry=1)
    at /build/glib2.0-b4FPyK/glib2.0-2.48.2/./glib/gmain.c:3901
#24 0x00007f57ef01609f in QEventDispatcherGlib::processEvents (this=0x7f57c00008c0, flags=...)
    at kernel/qeventdispatcher_glib.cpp:423
#25 0x00007f57eefbd5ba in QEventLoop::exec (this=this@entry=0x7f57cf5c1c70, flags=..., flags@entry=...)
    at kernel/qeventloop.cpp:214
#26 0x00007f57eedf25e4 in QThread::exec (this=<optimized out>) at thread/qthread.cpp:525
#27 0x00007f57eedfd727 in QThreadPrivate::start (arg=0x2298920) at thread/qthread_unix.cpp:367
#28 0x00007f57f01916ba in start_thread (arg=0x7f57cf5c2700) at pthread_create.c:333
#29 0x00007f57ee4e841d in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:109

Thread 3 (Thread 3764.3766):
#0  0x00007f57ee4dc74d in poll () at ../sysdeps/unix/syscall-template.S:84
#1  0x00007f57e575c38c in g_main_context_poll (priority=2147483647, n_fds=2, fds=0x7f57c8003220, 
    timeout=<optimized out>, context=0x7f57c8000990)
    at /build/glib2.0-b4FPyK/glib2.0-2.48.2/./glib/gmain.c:4135
#2  g_main_context_iterate (context=context@entry=0x7f57c8000990, block=block@entry=1, 
---Type <return> to continue, or q <return> to quit---
    dispatch=dispatch@entry=1, self=<optimized out>)
    at /build/glib2.0-b4FPyK/glib2.0-2.48.2/./glib/gmain.c:3835
#3  0x00007f57e575c49c in g_main_context_iteration (context=0x7f57c8000990, may_block=may_block@entry=1)
    at /build/glib2.0-b4FPyK/glib2.0-2.48.2/./glib/gmain.c:3901
#4  0x00007f57ef01609f in QEventDispatcherGlib::processEvents (this=0x7f57c80008c0, flags=...)
    at kernel/qeventdispatcher_glib.cpp:423
#5  0x00007f57eefbd5ba in QEventLoop::exec (this=this@entry=0x7f57cfdc2c70, flags=..., flags@entry=...)
    at kernel/qeventloop.cpp:214
#6  0x00007f57eedf25e4 in QThread::exec (this=<optimized out>) at thread/qthread.cpp:525
#7  0x00007f57eedfd727 in QThreadPrivate::start (arg=0x229b150) at thread/qthread_unix.cpp:367
#8  0x00007f57f01916ba in start_thread (arg=0x7f57cfdc3700) at pthread_create.c:333
#9  0x00007f57ee4e841d in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:109

Thread 2 (Thread 3764.3765):
#0  0x00007f57ee4dc74d in poll () at ../sysdeps/unix/syscall-template.S:84
#1  0x00007f57e575c38c in g_main_context_poll (priority=2147483647, n_fds=5, fds=0x7f57d0014280, 
    timeout=<optimized out>, context=0x7f57d0001600)
    at /build/glib2.0-b4FPyK/glib2.0-2.48.2/./glib/gmain.c:4135
#2  g_main_context_iterate (context=context@entry=0x7f57d0001600, block=block@entry=1, 
    dispatch=dispatch@entry=1, self=<optimized out>)
    at /build/glib2.0-b4FPyK/glib2.0-2.48.2/./glib/gmain.c:3835
#3  0x00007f57e575c49c in g_main_context_iteration (context=0x7f57d0001600, may_block=may_block@entry=1)
    at /build/glib2.0-b4FPyK/glib2.0-2.48.2/./glib/gmain.c:3901
#4  0x00007f57ef01609f in QEventDispatcherGlib::processEvents (this=0x7f57d00008c0, flags=...)
    at kernel/qeventdispatcher_glib.cpp:423
#5  0x00007f57eefbd5ba in QEventLoop::exec (this=this@entry=0x7f57d4804c40, flags=..., flags@entry=...)
    at kernel/qeventloop.cpp:214
---Type <return> to continue, or q <return> to quit---
#6  0x00007f57eedf25e4 in QThread::exec (
    this=this@entry=0x7f57f0928d60 <(anonymous namespace)::Q_QGS__q_manager::innerFunction()::holder>)
    at thread/qthread.cpp:525
#7  0x00007f57f06aff35 in QDBusConnectionManager::run (
    this=0x7f57f0928d60 <(anonymous namespace)::Q_QGS__q_manager::innerFunction()::holder>)
    at qdbusconnection.cpp:178
#8  0x00007f57eedfd727 in QThreadPrivate::start (
    arg=0x7f57f0928d60 <(anonymous namespace)::Q_QGS__q_manager::innerFunction()::holder>)
    at thread/qthread_unix.cpp:367
#9  0x00007f57f01916ba in start_thread (arg=0x7f57d4805700) at pthread_create.c:333
#10 0x00007f57ee4e841d in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:109

Thread 1 (Thread 3764.3764):
#0  0x00007f57ee462bbc in _int_malloc (av=av@entry=0x7f57ee7a5b20 <main_arena>, bytes=bytes@entry=32)
    at malloc.c:3353
#1  0x00007f57ee465184 in __GI___libc_malloc (bytes=32) at malloc.c:2913
#2  0x00007f57ee838e78 in operator new(unsigned long) () from target:/usr/lib/x86_64-linux-gnu/libstdc++.so.6
#3  0x00007f57ef009cd3 in v_construct_helper<QRect> (x=0x7ffc757ae160)
    at ../../include/QtCore/5.11.1/QtCore/private/../../../../../src/corelib/kernel/qvariant_p.h:144
#4  v_construct<QRect> (copy=0x0, x=0x7ffc757ae160)
    at ../../include/QtCore/5.11.1/QtCore/private/../../../../../src/corelib/kernel/qvariant_p.h:162
#5  QVariantConstructor<(anonymous namespace)::CoreTypesFilter>::FilteredConstructor<QRect, true>::FilteredConstructor (this=<optimized out>, tc=<synthetic pointer>)
    at ../../include/QtCore/5.11.1/QtCore/private/../../../../../src/corelib/kernel/qvariant_p.h:351
#6  QVariantConstructor<(anonymous namespace)::CoreTypesFilter>::delegate<QRect> (this=<synthetic pointer>)
    at ../../include/QtCore/5.11.1/QtCore/private/../../../../../src/corelib/kernel/qvariant_p.h:372
#7  QMetaTypeSwitcher::switcher<void, QVariantConstructor<(anonymous namespace)::CoreTypesFilter> > (data=0x0, 
---Type <return> to continue, or q <return> to quit---
    type=<optimized out>, logic=<synthetic pointer>)
    at ../../include/QtCore/5.11.1/QtCore/private/../../../../../src/corelib/kernel/qmetatypeswitcher_p.h:74
#8  (anonymous namespace)::construct (x=0x7ffc757ae160, copy=0x0) at kernel/qvariant.cpp:118
#9  0x00007f57eeffdedf in QVariant::QVariant (this=0x7ffc757ae160, typeId=<optimized out>, 
    copy=<optimized out>) at kernel/qvariant.cpp:1830
#10 0x00007f57eefcdbda in QMetaProperty::read (this=this@entry=0x7ffc757ae200, object=object@entry=0x32a8700)
    at kernel/qmetaobject.cpp:3098
#11 0x00007f57eefea0ff in QObject::property (this=0x32a8700, name=name@entry=0x7f57f0db29c7 "geometry")
    at kernel/qobject.cpp:3951
#12 0x00007f57f0d9cff2 in KWin::EffectWindow::geometry (this=<optimized out>)
    at /workspace/build/libkwineffects/kwineffects.cpp:818
#13 0x00007f57f0db00d3 in KWin::EffectWindow::qt_static_metacall (_o=_o@entry=0x32e5bb0, 
    _c=_c@entry=QMetaObject::ReadProperty, _id=_id@entry=1, _a=_a@entry=0x7ffc757ae3e0)
    at /workspace/build/obj-x86_64-linux-gnu/libkwineffects/moc_kwineffects.cpp:1915
#14 0x00007f57f0db204b in KWin::EffectWindow::qt_metacall (this=this@entry=0x32e5bb0, 
    _c=_c@entry=QMetaObject::ReadProperty, _id=1, _a=_a@entry=0x7ffc757ae3e0)
    at /workspace/build/obj-x86_64-linux-gnu/libkwineffects/moc_kwineffects.cpp:2028
#15 0x00007f57f1413d55 in KWin::EffectWindowImpl::qt_metacall (this=0x32e5bb0, _c=QMetaObject::ReadProperty, 
    _id=<optimized out>, _a=0x7ffc757ae3e0) at /workspace/build/obj-x86_64-linux-gnu/moc_effects.cpp:465
#16 0x00007f57eefcdb56 in QMetaProperty::read (this=this@entry=0x7ffc757ae4d0, object=object@entry=0x32e5bb0)
    at kernel/qmetaobject.cpp:3105
#17 0x00007f57edbee66d in QScript::QtPropertyFunction::execute (this=this@entry=0x7f57a2b04080, 
    exec=exec@entry=0x7f57a2b80058, thisValue=..., thisValue@entry=..., args=...)
    at bridge/qscriptqobject.cpp:1102
#18 0x00007f57edbee6e9 in QScript::QtPropertyFunction::call (exec=0x7f57a2b80058, callee=0x7f57a2b04080, 
    thisValue=..., args=...) at bridge/qscriptqobject.cpp:1067
#19 0x00007f57edb03028 in QTJSC::NativeFuncWrapper::operator() (this=this@entry=0x7ffc757ae5c0, 
---Type <return> to continue, or q <return> to quit---
    exec=exec@entry=0x7f57a2b80058, jsobj=0x7f57a2b04080, thisValue=..., argList=...)
    at ../3rdparty/javascriptcore/JavaScriptCore/runtime/CallData.cpp:46
#20 0x00007f57edb62168 in QTJSC::PropertySlot::functionGetter (exec=0x7f57a2b80058, slot=...)
    at ../3rdparty/javascriptcore/JavaScriptCore/runtime/PropertySlot.cpp:38
#21 0x00007f57edaa2f00 in QTJSC::PropertySlot::getValue (propertyName=..., exec=<optimized out>, 
    this=<optimized out>) at ../3rdparty/javascriptcore/JavaScriptCore/runtime/PropertySlot.h:62
#22 QTJSC::JSValue::get (this=<optimized out>, exec=0x7f57a2b80058, propertyName=..., slot=...)
    at ../3rdparty/javascriptcore/JavaScriptCore/runtime/JSObject.h:619
#23 0x00007f57edadb6bf in QTJSC::cti_op_get_by_id_generic (args=0x7ffc757ae6b0)
    at ../3rdparty/javascriptcore/JavaScriptCore/jit/JITStubs.cpp:1237
#24 0x00007f571c02605f in ?? ()
#25 0x00007ffc757ae760 in ?? ()
#26 0x00007f57a2b04000 in ?? ()
#27 0x00007f57a80585c8 in ?? ()
#28 0x00007f57a805a0f0 in ?? ()
#29 0x00000000a8014230 in ?? ()
#30 0x00007ffc757ae780 in ?? ()
#31 0x00007ffc757ae7e0 in ?? ()
#32 0x00007ffc757aec50 in ?? ()
#33 0x00007ffc757ae770 in ?? ()
#34 0x00007f571c025580 in ?? ()
#35 0x00007f57a8016e30 in ?? ()
#36 0x00007f57a2b80058 in ?? ()
#37 0x00007f57c4109288 in ?? ()
#38 0x00007f57ede6dda8 in QTJSC::ExecutableAllocator::pageSize ()
   from target:/usr/lib/x86_64-linux-gnu/libQt5Script.so.5
#39 0x00007f57c4108000 in ?? ()
---Type <return> to continue, or q <return> to quit---
#40 0x00007f57a2b80000 in ?? ()
#41 0x0000000000000000 in ?? ()
Comment 4 Patrick Silva 2018-09-14 13:38:40 UTC
crash reproducible in plasma 5.14 beta on Arch Linux.
Comment 5 David Edmundson 2018-10-10 16:35:58 UTC
There is no default meta+R shortcut. Can you confirm what that shortcut is bound to?

From the trace I would assume it's some kwin script.
Comment 6 Alexander Mentyu 2018-10-10 17:29:14 UTC
I set it in Global Shortcuts -> KWin -> Resize Window. Maybe it could be default for KWin in next releases?
Comment 7 Patrick Silva 2018-10-26 12:53:29 UTC
Crash is still reproducible.

activate window resizing mode
move cursor to decrease the window size
press enter to apply the new window size
crash

Operating System: Arch Linux 
KDE Plasma Version: 5.14.2
Qt Version: 5.12.0 beta3
KDE Frameworks Version: 5.51.0
Comment 8 Vlad Zahorodnii 2018-11-13 08:35:50 UTC
Git commit 406b70b04e093c13faf763e2d885797ae037d806 by Vlad Zagorodniy.
Committed on 13/11/2018 at 08:28.
Pushed by vladz into branch 'Plasma/5.14'.

[wayland] Don't crash when resizing windows

Summary:
If you resize a decorated client by using the resize user action(press
Alt + F3 > More Actions > Resize), then KWin will crash because it gets
stuck in an infinite loop (AbstractClient::performMoveResize <->
ShellClient::setGeometry).

Here's how KWin gets stuck in that loop:
* when you finish resizing the client, AbstractClient::keyPressEvent
  will call AbstractClient::finishMoveResize;
* the first thing that finishMoveResize does is block geometry updates,
  then it does some clean up (e.g. reset the value of isMoveResize(), etc),
  updates the geometry of the client and when it's done, it will emit
  clientFinishUserMoveResized signal;
* when PointerInputRedirection notices that signal, it will call
  processDecorationMove on the client, which in its turn will indirectly
  call AbstractClient::startMoveResize;
* when it's time to go back to AbstractClient::keyPressEvent, geometry
  updates are unblocked and if there are any pending geometry updates,
  then ShellClient::setGeometry will be called;
* ShellClient::setGeometry will eventually call ShellClient::doSetGeometry;
* ShellClient::doSetGeometry will call AbstractClient::performMoveResize
  because AbstractClient::processDecorationMove indirectly called
  AbstractClient::startMoveResize;
* AbstractClient::performMoveResize calls ShellClient::setGeometry;
* (at this point, KWin got stuck in the infinite loop)

This change swaps setMoveResizePointerButtonDown and finishMoveResize,
so processDecorationMove won't indirectly call startMoveResize.
FIXED-IN: 5.14.4

Reviewers: #kwin, davidedmundson

Reviewed By: #kwin, davidedmundson

Subscribers: kwin

Tags: #kwin

Differential Revision: https://phabricator.kde.org/D16846

M  +2    -2    abstract_client.cpp

https://commits.kde.org/kwin/406b70b04e093c13faf763e2d885797ae037d806