From 2d0e2c3921e37dc6df8113d7623d3af6e052ba1e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20Gr=C3=A4=C3=9Flin?= Date: Wed, 16 Sep 2009 09:57:17 +0000 Subject: [PATCH] Adding a safety check in coverswitch so that the input window is not destroyed twice. BUG: 207554 svn path=/trunk/KDE/kdebase/workspace/; revision=1024275 --- effects/coverswitch/coverswitch.cpp | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/effects/coverswitch/coverswitch.cpp b/effects/coverswitch/coverswitch.cpp index d4fc9dd4fe..fd9fb02287 100644 --- a/effects/coverswitch/coverswitch.cpp +++ b/effects/coverswitch/coverswitch.cpp @@ -1433,9 +1433,14 @@ void CoverSwitchEffect::windowInputMouseEvent( Window w, QEvent* e ) void CoverSwitchEffect::abort() { - effects->unrefTabBox(); + // it's possible that abort is called after tabbox has been closed + // in this case the cleanup is already done (see bug 207554) + if( mActivated ) + { + effects->unrefTabBox(); + effects->destroyInputWindow( input ); + } effects->setActiveFullScreenEffect( 0 ); - effects->destroyInputWindow( input ); mActivated = false; stop = false; stopRequested = false;