Bug 395666 - yakuake crashes on multiple touches on the touchscreen
Summary: yakuake crashes on multiple touches on the touchscreen
Status: RESOLVED FIXED
Alias: None
Product: konsole
Classification: Applications
Component: copy-paste (show other bugs)
Version: 18.04.2
Platform: Arch Linux Linux
: NOR crash
Target Milestone: ---
Assignee: Konsole Developer
URL:
Keywords: drkonqi, junior-jobs
: 396023 (view as bug list)
Depends on:
Blocks:
 
Reported: 2018-06-20 20:30 UTC by Leandro Santiago da Silva
Modified: 2018-09-30 17:48 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Leandro Santiago da Silva 2018-06-20 20:30:02 UTC
Application: yakuake (3.0.5)

Qt Version: 5.11.0
Frameworks Version: 5.47.0
Operating System: Linux 4.14.49-1-lts x86_64
Distribution (Platform): Archlinux Packages

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

I have a dell laptop which supports up to 10 touches. I am using kwin_wayland and and tried touching with several (maybe 8) fingers when yakuake is in full screen.

- Unusual behavior I noticed:
yakuake crashed

- Custom settings of the application:
kwin_wayland, yakuake in fullscreen

The crash can be reproduced every time.

-- Backtrace:
Application: Yakuake (yakuake), signal: Segmentation fault
Using host libthread_db library "/usr/lib/libthread_db.so.1".
[Current thread is 1 (Thread 0x7f02bdb2d800 (LWP 14727))]

Thread 3 (Thread 0x7f029d22f700 (LWP 14730)):
#0  0x00007f02b4085ffc in pthread_cond_wait@@GLIBC_2.3.2 () from /usr/lib/libpthread.so.0
#1  0x00007f029e00b0a4 in ?? () from /usr/lib/dri/i965_dri.so
#2  0x00007f029e00ad98 in ?? () from /usr/lib/dri/i965_dri.so
#3  0x00007f02b4080075 in start_thread () from /usr/lib/libpthread.so.0
#4  0x00007f02b808153f in clone () from /usr/lib/libc.so.6

Thread 2 (Thread 0x7f02a84ec700 (LWP 14728)):
#0  0x00007f02b8072934 in read () from /usr/lib/libc.so.6
#1  0x00007f02b22aaed1 in ?? () from /usr/lib/libglib-2.0.so.0
#2  0x00007f02b2264ff8 in g_main_context_check () from /usr/lib/libglib-2.0.so.0
#3  0x00007f02b22654c6 in ?? () from /usr/lib/libglib-2.0.so.0
#4  0x00007f02b226563e in g_main_context_iteration () from /usr/lib/libglib-2.0.so.0
#5  0x00007f02b8992e64 in QEventDispatcherGlib::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib/libQt5Core.so.5
#6  0x00007f02b893e85c in QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib/libQt5Core.so.5
#7  0x00007f02b8787ac9 in QThread::exec() () from /usr/lib/libQt5Core.so.5
#8  0x00007f02ba5a3976 in ?? () from /usr/lib/libQt5DBus.so.5
#9  0x00007f02b8791b95 in ?? () from /usr/lib/libQt5Core.so.5
#10 0x00007f02b4080075 in start_thread () from /usr/lib/libpthread.so.0
#11 0x00007f02b808153f in clone () from /usr/lib/libc.so.6

Thread 1 (Thread 0x7f02bdb2d800 (LWP 14727)):
[KCrash Handler]
#6  0x00007f02b8964d30 in QMimeData::text() const () from /usr/lib/libQt5Core.so.5
#7  0x00007f029c38c6ea in Konsole::TerminalDisplay::doDrag() () from /usr/lib/libkonsoleprivate.so.18
#8  0x00007f029c38d25b in Konsole::TerminalDisplay::mouseMoveEvent(QMouseEvent*) () from /usr/lib/libkonsoleprivate.so.18
#9  0x00007f02b96ef058 in QWidget::event(QEvent*) () from /usr/lib/libQt5Widgets.so.5
#10 0x00007f029c394034 in Konsole::TerminalDisplay::event(QEvent*) () from /usr/lib/libkonsoleprivate.so.18
#11 0x00007f02b96af984 in QApplicationPrivate::notify_helper(QObject*, QEvent*) () from /usr/lib/libQt5Widgets.so.5
#12 0x00007f02b96b746a in QApplication::notify(QObject*, QEvent*) () from /usr/lib/libQt5Widgets.so.5
#13 0x00007f02b893fbc9 in QCoreApplication::notifyInternal2(QObject*, QEvent*) () from /usr/lib/libQt5Core.so.5
#14 0x00007f02b96b6781 in QApplicationPrivate::sendMouseEvent(QWidget*, QMouseEvent*, QWidget*, QWidget*, QWidget**, QPointer<QWidget>&, bool) () from /usr/lib/libQt5Widgets.so.5
#15 0x00007f02b970a38c in ?? () from /usr/lib/libQt5Widgets.so.5
#16 0x00007f02b970cfd5 in ?? () from /usr/lib/libQt5Widgets.so.5
#17 0x00007f02b96af984 in QApplicationPrivate::notify_helper(QObject*, QEvent*) () from /usr/lib/libQt5Widgets.so.5
#18 0x00007f02b96b725b in QApplication::notify(QObject*, QEvent*) () from /usr/lib/libQt5Widgets.so.5
#19 0x00007f02b893fbc9 in QCoreApplication::notifyInternal2(QObject*, QEvent*) () from /usr/lib/libQt5Core.so.5
#20 0x00007f02b8ee7596 in QGuiApplicationPrivate::processMouseEvent(QWindowSystemInterfacePrivate::MouseEvent*) () from /usr/lib/libQt5Gui.so.5
#21 0x00007f02b8ee67f8 in QGuiApplicationPrivate::processTouchEvent(QWindowSystemInterfacePrivate::TouchEvent*) () from /usr/lib/libQt5Gui.so.5
#22 0x00007f02b8ee94e6 in QGuiApplicationPrivate::processWindowSystemEvent(QWindowSystemInterfacePrivate::WindowSystemEvent*) () from /usr/lib/libQt5Gui.so.5
#23 0x00007f02b8ec0a5c in QWindowSystemInterface::sendWindowSystemEvents(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib/libQt5Gui.so.5
#24 0x00007f02abc80f7d in ?? () from /usr/lib/libQt5WaylandClient.so.5
#25 0x00007f02b893e85c in QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib/libQt5Core.so.5
#26 0x00007f02b8946b56 in QCoreApplication::exec() () from /usr/lib/libQt5Core.so.5
#27 0x00005654f1d02c92 in ?? ()
#28 0x00007f02b7fac06b in __libc_start_main () from /usr/lib/libc.so.6
#29 0x00005654f1d02d2a in _start ()

Reported using DrKonqi
Comment 1 Leandro Santiago da Silva 2018-06-20 20:31:52 UTC
I mean, "whose screen supports up to 10 simultaneous touches" :-)
Comment 2 Christoph Feck 2018-07-18 21:20:02 UTC
QMimiData can be a nullptr in wayland, see e.g. https://cgit.kde.org/kolourpaint.git/commit/?id=4b280d0942b4c7b0248c96d0077ebab8c5a2673d
Comment 3 Christoph Feck 2018-07-31 00:14:49 UTC
*** Bug 396023 has been marked as a duplicate of this bug. ***
Comment 4 Gabriel Verdi 2018-09-29 09:55:56 UTC
I submitted a patch to fix this bug here https://phabricator.kde.org/D15794
Comment 5 Kurt Hindenburg 2018-09-30 17:48:36 UTC
Git commit bfb91aac49f21b2bdf9ee2b64feaf28d87569bc4 by Kurt Hindenburg.
Committed on 30/09/2018 at 17:48.
Pushed by hindenburg into branch 'master'.

Check clipboard->mimeData() is valid

Summary:

Bug reported crashes on yakuake in a wayland session. Further
investigation revealed that other KDE product Kolourpaint experienced
nullptr on wayland while getting MimeData which was consistent with
the stacktrace provided by the author of the bug.

This diff validates the presence of MimeData before proceeding with
the drag action.

Test Plan:
1. Use wayland session
2. Open Yakuake in fullscreen
3. With a touch enabled laptop, scroll with many fingers (possibly 8)
4. Yakuake should not crash

Reviewers: #konsole, hindenburg

Reviewed By: #konsole, hindenburg

Subscribers: anthonyfieroni, ngraham, konsole-devel

Tags: #konsole

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

M  +7    -3    src/TerminalDisplay.cpp

https://commits.kde.org/konsole/bfb91aac49f21b2bdf9ee2b64feaf28d87569bc4