Summary: | neofetch and right mouse button menu at the same time will cause a crash | ||
---|---|---|---|
Product: | [Applications] konsole | Reporter: | MuqiuHan <muqiu-han> |
Component: | general | Assignee: | Konsole Developer <konsole-devel> |
Status: | RESOLVED FIXED | ||
Severity: | crash | CC: | a.samirh78, alpha_one_x86, bernhardu, davispuh, gavin.grotegut, jimtahu, jskitty, ke7in.dev, ninjalj, sm+kdebugs, violanteleonardo, wuseman |
Priority: | HI | Keywords: | drkonqi |
Version: | 22.04.1 | ||
Target Milestone: | --- | ||
Platform: | unspecified | ||
OS: | Linux | ||
Latest Commit: | https://invent.kde.org/utilities/konsole/commit/bc127dd2c1c30e8af9061809fcf217dfabf915d8 | Version Fixed In: | v22.12.0 |
Sentry Crash Report: | |||
Attachments: |
attachment-26605-0.html
New crash information added by DrKonqi |
Description
MuqiuHan
2022-05-21 00:59:06 UTC
Please install the debuginfo (or equivalent in your distro) and provide a new backtrace. Also, how are you making neofetch run when konsole starts? 在 2022年5月21日星期六 CST 下午6:37:59,您写道:
> Also, how are you making neofetch run when konsole starts?
This is self-initiated by my OS (ArcoLinux), similar to adding neofetch to
~/.bashrc to make Konsole call neofetch at boot time.
Thank you very much for your concern, I fixed the problem after the update of
the system.
By fixed you mean this report can be closed? Created attachment 149125 [details] attachment-26605-0.html Yes, you can close this report Get Outlook for Android<https://aka.ms/AAb9ysg> ________________________________ From: Ahmad Samir <bugzilla_noreply@kde.org> Sent: Saturday, May 21, 2022 11:35:00 PM To: muqiu-han@outlook.com <muqiu-han@outlook.com> Subject: [konsole] [Bug 454122] neofetch and right mouse button menu at the same time will cause a crash https://bugs.kde.org/show_bug.cgi?id=454122 --- Comment #3 from Ahmad Samir <a.samirh78@gmail.com> --- By fixed you mean this report can be closed? -- You are receiving this mail because: You reported the bug. Created attachment 152414 [details]
New crash information added by DrKonqi
konsole (22.08.1) using Qt 5.15.6
Konsole consistently (with 100% reliability for me) crashes when performing a long task (i.e: the beginning of an ssh prompt) and right-clicking the terminal with the mouse immediately after, I have not tweaked Konsole's settings much (if at all, from memory) and I have updated to the latest of all core Arch repositories with my system in general being very stable.
-- Backtrace (Reduced):
#4 0x00007fd35e3ad104 in Konsole::ProcessInfo::isValid() const () from /usr/lib/libkonsoleprivate.so.1
#5 0x00007fd35e43eda8 in Konsole::Session::getUrl() () from /usr/lib/libkonsoleprivate.so.1
#6 0x00007fd35e440e0f in Konsole::SessionController::url() const () from /usr/lib/libkonsoleprivate.so.1
#7 0x00007fd35e455191 in Konsole::SessionController::showDisplayContextMenu(QPoint const&) () from /usr/lib/libkonsoleprivate.so.1
[...]
#9 0x00007fd35e39d08a in Konsole::TerminalDisplay::configureRequest(QPoint const&) () from /usr/lib/libkonsoleprivate.so.1
I received this crash too with current Debian testing. Below the top of the backtrace without and the full backtrace with debug symbols installed. While in my first crash I think I had also a ssh connection open, I could reproduce the issue - with installing neofetch - starting a new konsole - starting inside neofetch - right click while neofetch was still running. Interesting looks the call to `Konsole::ProcessInfo::isValid` with this=0x0. I assume these bugs are duplicates to this one: 458157 460764 And bug 391447 seems also kind of related, while it was closed with a commit changing this: - if (isForegroundProcessActive()) { + if (isForegroundProcessActive() && _foregroundProcessInfo->isValid()) { Maybe extend this check by following: - if (isForegroundProcessActive() && _foregroundProcessInfo->isValid()) { + if (isForegroundProcessActive() && _foregroundProcessInfo && _foregroundProcessInfo->isValid()) { Kind regards, Bernhard Application: Konsole (konsole), signal: Segmentation fault [KCrash Handler] #4 0x00007f85356d0ad0 in Konsole::ProcessInfo::isValid() const () from /lib/x86_64-linux-gnu/libkonsoleprivate.so.1 #5 0x00007f85357609f4 in Konsole::Session::getUrl() () from /lib/x86_64-linux-gnu/libkonsoleprivate.so.1 #6 0x00007f8535768b71 in Konsole::SessionController::url() const () from /lib/x86_64-linux-gnu/libkonsoleprivate.so.1 #7 0x00007f8535776bdc in Konsole::SessionController::showDisplayContextMenu(QPoint const&) () from /lib/x86_64-linux-gnu/libkonsoleprivate.so.1 ... konsole-dbgsym 4:22.08.1-1 konsole-kpart-dbgsym 4:22.08.1-1 libqt5core5a-dbgsym 5.15.6+dfsg-2 libqt5gui5-dbgsym 5.15.6+dfsg-2 libqt5widgets5-dbgsym 5.15.6+dfsg-2 libglib2.0-0-dbgsym 2.74.1-1 Application: Konsole (konsole), signal: Segmentation fault [KCrash Handler] #4 Konsole::ProcessInfo::isValid (this=0x0) at /usr/include/x86_64-linux-gnu/qt5/QtCore/qflags.h:151 #5 0x00007f85357609f4 in Konsole::Session::getUrl (this=0x5646bfb35520) at ./src/session/Session.cpp:1232 #6 0x00007f8535768b71 in Konsole::SessionController::url (this=<optimized out>) at ./src/session/SessionController.cpp:379 #7 0x00007f8535776bdc in Konsole::SessionController::showDisplayContextMenu (this=0x5646bf563fb0, position=...) at ./src/session/SessionController.cpp:1891 #8 0x00007f85340e8caf in QtPrivate::QSlotObjectBase::call (a=0x7ffe7043e5c0, r=0x5646bf563fb0, this=0x5646bfbdbce0) at ../../include/QtCore/../../src/corelib/kernel/qobjectdefs_impl.h:398 #9 doActivate<false> (sender=0x5646bf95cea0, signal_index=12, argv=0x7ffe7043e5c0) at kernel/qobject.cpp:3919 #10 0x00007f85340e1f4f in QMetaObject::activate (sender=sender@entry=0x5646bf95cea0, m=m@entry=0x7f8535803be0 <Konsole::TerminalDisplay::staticMetaObject>, local_signal_index=local_signal_index@entry=5, argv=argv@entry=0x7ffe7043e5c0) at kernel/qobject.cpp:3979 #11 0x00007f85356ba575 in Konsole::TerminalDisplay::configureRequest (this=this@entry=0x5646bf95cea0, _t1=...) at ./obj-x86_64-linux-gnu/src/konsoleprivate_autogen/DRAQINE3W2/moc_TerminalDisplay.cpp:398 #12 0x00007f853573fc8f in Konsole::TerminalDisplay::mousePressEvent (this=0x5646bf95cea0, ev=0x7ffe7043eb10) at ./src/terminalDisplay/TerminalDisplay.cpp:1168 #13 0x00007f8534da4ce8 in QWidget::event (this=0x5646bf95cea0, event=0x7ffe7043eb10) at kernel/qwidget.cpp:9034 #14 0x00007f8534d62f5e in QApplicationPrivate::notify_helper (this=this@entry=0x5646bf4211d0, receiver=receiver@entry=0x5646bf95cea0, e=e@entry=0x7ffe7043eb10) at kernel/qapplication.cpp:3637 #15 0x00007f8534d6b502 in QApplication::notify (this=<optimized out>, receiver=0x5646bf95cea0, e=<optimized out>) at kernel/qapplication.cpp:3081 #16 0x00007f85340b1718 in QCoreApplication::notifyInternal2 (receiver=0x5646bf95cea0, event=0x7ffe7043eb10) at kernel/qcoreapplication.cpp:1064 #17 0x00007f8534d6960e in QApplicationPrivate::sendMouseEvent (receiver=receiver@entry=0x5646bf95cea0, event=event@entry=0x7ffe7043eb10, alienWidget=<optimized out>, nativeWidget=0x5646bf74f790, buttonDown=buttonDown@entry=0x7f85352a69f0 <qt_button_down>, lastMouseReceiver=..., spontaneous=true, onlyDispatchEnterLeave=false) at kernel/qapplication.cpp:2619 #18 0x00007f8534dbdaf8 in QWidgetWindow::handleMouseEvent (this=0x5646bf779c80, event=0x7ffe7043edc0) at kernel/qwidgetwindow.cpp:683 #19 0x00007f8534dc0e80 in QWidgetWindow::event (this=0x5646bf779c80, event=0x7ffe7043edc0) at kernel/qwidgetwindow.cpp:300 #20 0x00007f8534d62f5e in QApplicationPrivate::notify_helper (this=<optimized out>, receiver=0x5646bf779c80, e=0x7ffe7043edc0) at kernel/qapplication.cpp:3637 #21 0x00007f85340b1718 in QCoreApplication::notifyInternal2 (receiver=0x5646bf779c80, event=0x7ffe7043edc0) at kernel/qcoreapplication.cpp:1064 #22 0x00007f853453d6bd in QGuiApplicationPrivate::processMouseEvent (e=0x5646bfd264b0) at kernel/qguiapplication.cpp:2285 #23 0x00007f8534511e1c in QWindowSystemInterface::sendWindowSystemEvents (flags=flags@entry=...) at kernel/qwindowsysteminterface.cpp:1169 #24 0x00007f852defc0fa in xcbSourceDispatch (source=<optimized out>) at ./src/plugins/platforms/xcb/qxcbeventdispatcher.cpp:105 #25 0x00007f8532468799 in g_main_dispatch (context=0x7f8528005010) at ../../../glib/gmain.c:3444 #26 g_main_context_dispatch (context=context@entry=0x7f8528005010) at ../../../glib/gmain.c:4162 #27 0x00007f8532468a28 in g_main_context_iterate (context=context@entry=0x7f8528005010, block=block@entry=1, dispatch=dispatch@entry=1, self=<optimized out>) at ../../../glib/gmain.c:4238 #28 0x00007f8532468abc in g_main_context_iteration (context=0x7f8528005010, may_block=1) at ../../../glib/gmain.c:4303 #29 0x00007f85341094b6 in QEventDispatcherGlib::processEvents (this=0x5646bf4f66c0, flags=...) at kernel/qeventdispatcher_glib.cpp:423 #30 0x00007f85340b019b in QEventLoop::exec (this=this@entry=0x7ffe7043f0f0, flags=..., flags@entry=...) at ../../include/QtCore/../../src/corelib/global/qflags.h:69 #31 0x00007f85340b8306 in QCoreApplication::exec () at ../../include/QtCore/../../src/corelib/global/qflags.h:121 #32 0x00005646bdbc4e4c in ?? () #33 0x00007f853362920a in __libc_start_call_main (main=main@entry=0x5646bdbc4690, argc=argc@entry=3, argv=argv@entry=0x7ffe7043f418) at ../sysdeps/nptl/libc_start_call_main.h:58 #34 0x00007f85336292bc in __libc_start_main_impl (main=0x5646bdbc4690, argc=3, argv=0x7ffe7043f418, init=<optimized out>, fini=<optimized out>, rtld_fini=<optimized out>, stack_end=0x7ffe7043f408) at ../csu/libc-start.c:389 #35 0x00005646bdbc5301 in ?? () [Inferior 1 (process 16913) detached] A short addition: I could reproduce it inside a rr-debugger recording. It looks to me like updateForegroundProcessInfo (which sets _foregroundProcessInfo) was called the last time even before the neofetch process got started. Therefore _foregroundProcessInfo contains that old "state" while isForegroundProcessActive is returning the current "state". Another place which calls isForegroundProcessActive is calling updateForegroundProcessInfo immediately after it. Therefore maybe this change might be considered? - if (isForegroundProcessActive() && _foregroundProcessInfo->isValid()) { + if (isForegroundProcessActive() && updateForegroundProcessInfo() && _foregroundProcessInfo && _foregroundProcessInfo->isValid()) { A possibly relevant merge request was started @ https://invent.kde.org/utilities/konsole/-/merge_requests/772 *** Bug 460764 has been marked as a duplicate of this bug. *** *** Bug 462104 has been marked as a duplicate of this bug. *** Git commit bc127dd2c1c30e8af9061809fcf217dfabf915d8 by Kurt Hindenburg, on behalf of Luis Javier Merino Morán. Committed on 25/11/2022 at 00:58. Pushed by hindenburg into branch 'master'. Update foreground pgroup info before accessing it Fixes a potential crash when opening the right mouse button context menu just after launching some process in the shell, before konsole has had any chance to update the foreground process group information. Related: bug 458157 M +1 -1 src/session/Session.cpp https://invent.kde.org/utilities/konsole/commit/bc127dd2c1c30e8af9061809fcf217dfabf915d8 *** Bug 462621 has been marked as a duplicate of this bug. *** This is awesome! I had this same crash happen so often (not related to neofetch) and was really annoying me. ``` #5 0x00007fd9fa75f104 in Konsole::ProcessInfo::isValid() const () from /usr/lib/libkonsoleprivate.so.1 #6 0x00007fd9fa7f0da8 in Konsole::Session::getUrl() () from /usr/lib/libkonsoleprivate.so.1 #7 0x00007fd9fa7f2e0f in Konsole::SessionController::url() const () from /usr/lib/libkonsoleprivate.so.1 #8 0x00007fd9fa807191 in Konsole::SessionController::showDisplayContextMenu(QPoint const&) () from /usr/lib/libkonsoleprivate.so.1 #9 0x00007fd9f9385381 in ?? () from /usr/lib/libQt5Core.so.5 #10 0x00007fd9fa74f08a in Konsole::TerminalDisplay::configureRequest(QPoint const&) () from /usr/lib/libkonsoleprivate.so.1 #11 0x00007fd9fa7c8c93 in Konsole::TerminalDisplay::mousePressEvent(QMouseEvent*) () from /usr/lib/libkonsoleprivate.so.1 #12 0x00007fd9f9f1945b in QWidget::event(QEvent*) () from /usr/lib/libQt5Widgets.so.5 #13 0x00007fd9f9ee2b1c in QApplicationPrivate::notify_helper(QObject*, QEvent*) () from /usr/lib/libQt5Widgets.so.5 #14 0x00007fd9f9ee8339 in QApplication::notify(QObject*, QEvent*) () from /usr/lib/libQt5Widgets.so.5 #15 0x00007fd9f9354b88 in QCoreApplication::notifyInternal2(QObject*, QEvent*) () from /usr/lib/libQt5Core.so.5 #16 0x00007fd9f9ee6337 in QApplicationPrivate::sendMouseEvent(QWidget*, QMouseEvent*, QWidget*, QWidget*, QWidget**, QPointer<QWidget>&,bool, bool) () from /usr/lib/libQt5Widgets.so.5 #17 0x00007fd9f9f373b5 in ?? () from /usr/lib/libQt5Widgets.so.5 #18 0x00007fd9f9f3915e in ?? () from /usr/lib/libQt5Widgets.so.5 #19 0x00007fd9f9ee2b1c in QApplicationPrivate::notify_helper(QObject*, QEvent*) () from /usr/lib/libQt5Widgets.so.5 #20 0x00007fd9f9354b88 in QCoreApplication::notifyInternal2(QObject*, QEvent*) () from /usr/lib/libQt5Core.so.5 #21 0x00007fd9f984213c in QGuiApplicationPrivate::processMouseEvent(QWindowSystemInterfacePrivate::MouseEvent*) () from /usr/lib/libQt5Gui.so.5 #22 0x00007fd9f982b985 in QWindowSystemInterface::sendWindowSystemEvents(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib/libQt5Gui.so.5 #23 0x00007fd9f260b5f0 in ?? () from /usr/lib/libQt5XcbQpa.so.5 #24 0x00007fd9f6ee581b in g_main_context_dispatch () from /usr/lib/libglib-2.0.so.0 #25 0x00007fd9f6f3bec9 in ?? () from /usr/lib/libglib-2.0.so.0 #26 0x00007fd9f6ee40d2 in g_main_context_iteration () from /usr/lib/libglib-2.0.so.0 #27 0x00007fd9f939f50c in QEventDispatcherGlib::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib/libQt5Core.so.5 #28 0x00007fd9f934d32c in QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib/libQt5Core.so.5 #29 0x00007fd9f9357e59 in QCoreApplication::exec() () from /usr/lib/libQt5Core.so.5 #30 0x000055d8d537ab65 in ?? () #31 0x00007fd9f8ccb290 in ?? () from /usr/lib/libc.so.6 #32 0x00007fd9f8ccb34a in __libc_start_main () from /usr/lib/libc.so.6 #33 0x000055d8d537b425 in ?? () ``` And now I wanted to look into it why it happens but turns out it's already fixed so I wasn't able to reproduce it anymore on latest git master :) Application: konsole (22.08.3) QT_VERSION = 331522 QT_VERSION_STR = 5.15.2 Operating System: Linux 5.10.156-gentoo-x86_64 Windowing System: X11 Distribution: Gentoo QMAKE_SPEC:linux-g++ QMAKE_XSPEC:linux-g++ QMAKE_VERSION:3.1 QT_VERSION:5.15.7 -- Information about the crash: It happens various times, for example when you ssh to a connection and the SSH Manager changes the profile and if you cancel the connection with ctrl+c and have to right-click in terminal windwo e has returned to default profile, it crashes many times. Application: Konsole (konsole), signal: Segmentation fault [KCrash Handler] #4 0x00007ff52a0e0cf0 in Konsole::ProcessInfo::isValid() const () from /usr/lib64/libkonsoleprivate.so.1 #5 0x00007ff52a0907f4 in Konsole::Session::getUrl() () from /usr/lib64/libkonsoleprivate.so.1 #6 0x00007ff52a0990e2 in Konsole::SessionController::url() const () from /usr/lib64/libkonsoleprivate.so.1 #7 0x00007ff52a0a716f in Konsole::SessionController::showDisplayContextMenu(QPoint const&) () from /usr/lib64/libkonsoleprivate.so.1 #8 0x00007ff528eb1d0e in ?? () from /usr/lib64/libQt5Core.so.5 #9 0x00007ff52a0cbc65 in Konsole::TerminalDisplay::configureRequest(QPoint const&) () from /usr/lib64/libkonsoleprivate.so.1 #10 0x00007ff52a14f03a in Konsole::TerminalDisplay::mousePressEvent(QMouseEvent*) () from /usr/lib64/libkonsoleprivate.so.1 #11 0x00007ff529956378 in QWidget::event(QEvent*) () from /usr/lib64/libQt5Widgets.so.5 #12 0x00007ff5299146df in QApplicationPrivate::notify_helper(QObject*, QEvent*) () from /usr/lib64/libQt5Widgets.so.5 #13 0x00007ff52991c1aa in QApplication::notify(QObject*, QEvent*) () from /usr/lib64/libQt5Widgets.so.5 #14 0x00007ff528e7f398 in QCoreApplication::notifyInternal2(QObject*, QEvent*) () from /usr/lib64/libQt5Core.so.5 #15 0x00007ff52991acc6 in QApplicationPrivate::sendMouseEvent(QWidget*, QMouseEvent*, QWidget*, QWidget*, QWidget**, QPointer<QWidget>&, bool, bool) () from /usr/lib64/libQt5Widgets.so.5 #16 0x00007ff52996f11a in ?? () from /usr/lib64/libQt5Widgets.so.5 #17 0x00007ff529972265 in ?? () from /usr/lib64/libQt5Widgets.so.5 #18 0x00007ff5299146df in QApplicationPrivate::notify_helper(QObject*, QEvent*) () from /usr/lib64/libQt5Widgets.so.5 #19 0x00007ff528e7f398 in QCoreApplication::notifyInternal2(QObject*, QEvent*) () from /usr/lib64/libQt5Core.so.5 #20 0x00007ff52933b51d in QGuiApplicationPrivate::processMouseEvent(QWindowSystemInterfacePrivate::MouseEvent*) () from /usr/lib64/libQt5Gui.so.5 #21 0x00007ff52931b3cb in QWindowSystemInterface::sendWindowSystemEvents(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib64/libQt5Gui.so.5 #22 0x00007ff52382e11a in ?? () from /usr/lib64/libQt5XcbQpa.so.5 #23 0x00007ff52717493b in g_main_context_dispatch () from /usr/lib64/libglib-2.0.so.0 #24 0x00007ff527174be8 in ?? () from /usr/lib64/libglib-2.0.so.0 #25 0x00007ff527174c9f in g_main_context_iteration () from /usr/lib64/libglib-2.0.so.0 #26 0x00007ff528ecf936 in QEventDispatcherGlib::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib64/libQt5Core.so.5 #27 0x00007ff528e7de23 in QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib64/libQt5Core.so.5 #28 0x00007ff528e86110 in QCoreApplication::exec() () from /usr/lib64/libQt5Core.so.5 #29 0x00005580ae1a7e2a in ?? () #30 0x00007ff52884b20a in ?? () from /lib64/libc.so.6 #31 0x00007ff52884b2bc in __libc_start_main () from /lib64/libc.so.6 #32 0x00005580ae1a82c1 in ?? () [Inferior 1 (process 1324) detached] Fixed in 22.12.0 (https://invent.kde.org/utilities/konsole/-/commit/65c7187f8c16c7eeb68652633418b8ef1a0c94a0) *** Bug 464448 has been marked as a duplicate of this bug. *** *** Bug 463654 has been marked as a duplicate of this bug. *** *** Bug 465885 has been marked as a duplicate of this bug. *** |