summaryrefslogtreecommitdiffstats
path: root/src/gui
diff options
context:
space:
mode:
authormread <qt-info@nokia.com>2011-10-18 12:51:56 (GMT)
committermread <qt-info@nokia.com>2011-10-18 13:13:14 (GMT)
commitc838a413ee15b5ee872769f914f76ed3925b2201 (patch)
treec9cc3a0e4d92ac386707a38d8c0810ce997ae21b /src/gui
parentb7179d6f284e277b84c54226be05832a25576387 (diff)
downloadQt-c838a413ee15b5ee872769f914f76ed3925b2201.zip
Qt-c838a413ee15b5ee872769f914f76ed3925b2201.tar.gz
Qt-c838a413ee15b5ee872769f914f76ed3925b2201.tar.bz2
Catch potential throw in ~QSymbianControl
The call to topData() in ~QSymbianControl can create the required object if it does not already exist. This can then throw an exception if it fails, which is not allowed to escape the destructor. So it is caught and ignored. Task-number: QTBUG-4871 incidental finding Reviewed-by: Shane Kearns
Diffstat (limited to 'src/gui')
-rw-r--r--src/gui/kernel/qapplication_s60.cpp6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/gui/kernel/qapplication_s60.cpp b/src/gui/kernel/qapplication_s60.cpp
index 7d198ce..f1221eb 100644
--- a/src/gui/kernel/qapplication_s60.cpp
+++ b/src/gui/kernel/qapplication_s60.cpp
@@ -584,7 +584,11 @@ QSymbianControl::~QSymbianControl()
{
// Ensure backing store is deleted before the top-level
// window is destroyed
- qt_widget_private(qwidget)->topData()->backingStore.destroy();
+ QT_TRY {
+ qt_widget_private(qwidget)->topData()->backingStore.destroy();
+ } QT_CATCH(const std::exception&) {
+ // ignore exceptions, nothing can be done
+ }
if (S60->curWin == this)
S60->curWin = 0;