Bug 163205 - plasma crash when removing panel from within panel settings
Summary: plasma crash when removing panel from within panel settings
Status: RESOLVED FIXED
Alias: None
Product: plasma4
Classification: Plasma
Component: general (show other bugs)
Version: unspecified
Platform: Compiled Sources Linux
: NOR crash (vote)
Target Milestone: ---
Assignee: Plasma Bugs List
URL:
Keywords:
: 161899 163242 (view as bug list)
Depends on:
Blocks:
 
Reported: 2008-06-04 14:46 UTC by Viesturs Zarins
Modified: 2008-06-17 01:13 UTC (History)
2 users (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 Viesturs Zarins 2008-06-04 14:46:08 UTC
Version:            (using Devel)
Installed from:    Compiled sources
OS:                Linux

Running from kde4daily virtual image, updated today.

Steps to reproduce:
RClick on desktop->Add panel (New panel appears on top)
RClick on the new panel -> Panel settings (Panel settings panel appears)
Inside panel settings, click Remove this Panel (Confirmation dialog appears and plasma becomes unresponsive until the dialog is closed)
Click on an application 
Confirm panel removal (Plasma crashes)


This is not very stable, i can reproduce in approx 1 in 4 cases.

Backtrace:
Application: Plasma Workspace (plasma), signal SIGSEGV
[Thread debugging using libthread_db enabled]
[New Thread 0xb5743720 (LWP 5065)]
[New Thread 0xb2f54b90 (LWP 5075)]
[New Thread 0xb3dabb90 (LWP 5074)]
[KCrash handler]
#6  0x00000006 in ?? ()
#7  0xb64d404a in QGraphicsWidget::event ()
   from /home/kde4daily/install/qt-copy/lib/libQtGui.so.4
#8  0xb5ee981d in QApplicationPrivate::notify_helper ()
   from /home/kde4daily/install/qt-copy/lib/libQtGui.so.4
#9  0xb5ee9b03 in QApplication::notify ()
   from /home/kde4daily/install/qt-copy/lib/libQtGui.so.4
#10 0xb70b198b in KApplication::notify (this=0x805a3a0, receiver=0x8447848, 
    event=0xbf8b614c)
    at /home/kde4daily/src/kdelibs/kdeui/kernel/kapplication.cpp:311
#11 0xb67f568a in QCoreApplication::notifyInternal ()
   from /home/kde4daily/install/qt-copy/lib/libQtCore.so.4
#12 0xb77cec1b in QCoreApplication::sendEvent ()
   from /home/kde4daily/install/qt-copy/lib/libQtWebKit.so.4
#13 0xb64d44fa in QGraphicsWidget::sceneEvent ()
   from /home/kde4daily/install/qt-copy/lib/libQtGui.so.4
#14 0xb64acc59 in QGraphicsScenePrivate::sendEvent ()
   from /home/kde4daily/install/qt-copy/lib/libQtGui.so.4
#15 0xb64ae894 in QGraphicsScene::setFocusItem ()
   from /home/kde4daily/install/qt-copy/lib/libQtGui.so.4
#16 0xb649c304 in QGraphicsItem::clearFocus ()
   from /home/kde4daily/install/qt-copy/lib/libQtGui.so.4
#17 0xb64d6f0d in QGraphicsWidget::~QGraphicsWidget ()
   from /home/kde4daily/install/qt-copy/lib/libQtGui.so.4
#18 0xb7e7ae51 in ~Applet (this=0x8447848)
    at /home/kde4daily/src/kdebase/workspace/libs/plasma/applet.cpp:126
#19 0xb7ea7dbf in ~Containment (this=0x8447848)
    at /home/kde4daily/src/kdebase/workspace/libs/plasma/containment.cpp:103
#20 0xb3294954 in ~Panel (this=0x8447848)
    at /home/kde4daily/src/kdebase/workspace/plasma/containments/panel/panel.cpp:76
#21 0xb680462f in qDeleteInEventHandler ()
   from /home/kde4daily/install/qt-copy/lib/libQtCore.so.4
#22 0xb68087f4 in QObject::event ()
   from /home/kde4daily/install/qt-copy/lib/libQtCore.so.4
#23 0xb64d43e4 in QGraphicsWidget::event ()
   from /home/kde4daily/install/qt-copy/lib/libQtGui.so.4
#24 0xb5ee981d in QApplicationPrivate::notify_helper ()
   from /home/kde4daily/install/qt-copy/lib/libQtGui.so.4
#25 0xb5ee9b03 in QApplication::notify ()
   from /home/kde4daily/install/qt-copy/lib/libQtGui.so.4
#26 0xb70b198b in KApplication::notify (this=0x805a3a0, receiver=0x8447848, 
    event=0x84323c0)
    at /home/kde4daily/src/kdelibs/kdeui/kernel/kapplication.cpp:311
#27 0xb67f568a in QCoreApplication::notifyInternal ()
   from /home/kde4daily/install/qt-copy/lib/libQtCore.so.4
#28 0xb77cec1b in QCoreApplication::sendEvent ()
   from /home/kde4daily/install/qt-copy/lib/libQtWebKit.so.4
#29 0xb67f5ba2 in QCoreApplicationPrivate::sendPostedEvents ()
   from /home/kde4daily/install/qt-copy/lib/libQtCore.so.4
#30 0xb67f5d53 in QCoreApplication::sendPostedEvents ()
   from /home/kde4daily/install/qt-copy/lib/libQtCore.so.4
#31 0xb68265a2 in QCoreApplication::sendPostedEvents ()
   from /home/kde4daily/install/qt-copy/lib/libQtCore.so.4
#32 0xb68257b3 in postEventSourceDispatch ()
   from /home/kde4daily/install/qt-copy/lib/libQtCore.so.4
#33 0xb59b4bf8 in g_main_context_dispatch () from /usr/lib/libglib-2.0.so.0
#34 0xb59b7e5e in ?? () from /usr/lib/libglib-2.0.so.0
#35 0x08062498 in ?? ()
#36 0x00000000 in ?? ()
#0  0xb7f8c410 in __kernel_vsyscall ()
Comment 1 Viesturs Zarins 2008-06-04 14:59:49 UTC
Figured out a sequece to reliably reproduce the bug.

First open a application window (I have KMail), make it small, so you can see the top half of desktop. I also have konqui open, but minimized, maybe that's relevant.

Add a new panel to plasma (panel appears on top).
Click inside the KMail window (the window is now active - has blue lines in titlebar).
RClick on the new panel -> Panel settings (the KMail window is still active).
Click "Remove this Panel" inside panel settings (the KMail window is still active until the confirmation dialog appears and gets focus)
Now click on the KMail window (the window is active again)
Click back to the plasma dialog and click Remove (plasma crashes).
Comment 2 Aaron J. Seigo 2008-06-04 20:51:31 UTC
i can reproduce, here's a slightly better backtrace:

Application: Plasma Workspace (plasma), signal SIGSEGV
[?1034hUsing host libthread_db library "/lib/libthread_db.so.1".
[Thread debugging using libthread_db enabled]
[New Thread 0xb55df9a0 (LWP 28986)]
[New Thread 0xb1e18b90 (LWP 28990)]
[New Thread 0xb2d3fb90 (LWP 28989)]
[New Thread 0xb3841b90 (LWP 28988)]
[KCrash handler]
#6  0x00000005 in ?? ()
#7  0xb6391dea in QGraphicsWidget::event (this=0x88c5bf0, event=0xbffad55c)
    at graphicsview/qgraphicswidget.cpp:1153
#8  0xb5da3e0d in QApplicationPrivate::notify_helper (this=0x807ad88, 
    receiver=0x88c5bf0, e=0xbffad55c) at kernel/qapplication.cpp:3772
#9  0xb5da4126 in QApplication::notify (this=0x8075020, receiver=0x88c5bf0, 
    e=0xbffad55c) at kernel/qapplication.cpp:3366
#10 0xb6ffe763 in KApplication::notify (this=0x8075020, receiver=0x88c5bf0, 
    event=0xbffad55c)
    at /home/aseigo/kde4/KDE/kdelibs/kdeui/kernel/kapplication.cpp:311
#11 0xb66ee8d6 in QCoreApplication::notifyInternal (this=0x8075020, 
    receiver=0x88c5bf0, event=0xbffad55c) at kernel/qcoreapplication.cpp:583
#12 0xb77a0bab in QCoreApplication::sendEvent (receiver=0x88c5bf0, 
    event=0xbffad55c)
    at ../../../../include/QtCore/../../src/corelib/kernel/qcoreapplication.h:215
#13 0xb639229a in QGraphicsWidget::sceneEvent (this=0x88c5bf0, 
    event=0xbffad55c) at graphicsview/qgraphicswidget.cpp:1003
#14 0xb6369fd1 in QGraphicsScenePrivate::sendEvent (this=0x80be878, 
    item=0x88c5bf8, event=0xbffad55c) at graphicsview/qgraphicsscene.cpp:1046
#15 0xb636bc9c in QGraphicsScene::setFocusItem (this=0x80cb0d0, item=0x0, 
    focusReason=Qt::OtherFocusReason) at graphicsview/qgraphicsscene.cpp:2634
#16 0xb63591f6 in QGraphicsItem::clearFocus (this=0x88c5bf8)
    at graphicsview/qgraphicsitem.cpp:1871
#17 0xb6394d4b in ~QGraphicsWidget (this=0x88c5bf0)
    at graphicsview/qgraphicswidget.cpp:218
#18 0xb7e5cef5 in ~Applet (this=0x88c5bf0)
    at /home/aseigo/kde4/KDE/kdebase/workspace/libs/plasma/applet.cpp:121
#19 0xb7e8a649 in non-virtual thunk to Plasma::Containment::~Containment() ()
    at /home/aseigo/kde4/KDE/kdebase/workspace/libs/plasma/containment.cpp:103
#20 0x088c5bf0 in ?? ()
#21 0xb3d38ff4 in ?? () from /opt/kde4/lib/kde4/plasma_containment_panel.so
#22 0xbffad5f8 in ?? ()
#23 0xb3d359a4 in ~Panel (this=0x88c5bf0)
    at /home/aseigo/kde4/KDE/kdebase/workspace/plasma/containments/panel/panel.cpp:76
Backtrace stopped: frame did not save the PC
#0  0xffffe410 in __kernel_vsyscall ()
Comment 3 Aaron J. Seigo 2008-06-04 21:05:06 UTC
SVN commit 816760 by aseigo:

safety in removing panels, aka "work around the inane requirement to first remove items from the scene before deleting them if they are a QGraphicsWidget and have a layout"
BUG:163205


 M  +6 -1      applet.cpp  
 M  +1 -0      applet_p.h  
 M  +5 -1      containment.cpp  
 M  +2 -0      corona.cpp  


WebSVN link: http://websvn.kde.org/?view=rev&revision=816760
Comment 4 Sebastian Sauer 2008-06-04 21:09:52 UTC
*** Bug 161899 has been marked as a duplicate of this bug. ***
Comment 5 Sebastian Sauer 2008-06-17 01:13:31 UTC
*** Bug 163242 has been marked as a duplicate of this bug. ***