summaryrefslogtreecommitdiffstats
path: root/src/gui/inputmethod/qcoefepinputcontext_s60.cpp
diff options
context:
space:
mode:
authorShane Kearns <shane.kearns@sosco.com>2009-09-22 15:06:32 +0200
committerShane Kearns <shane.kearns@sosco.com>2009-09-22 16:32:49 +0200
commit24a928dd31ea54063b802cc2d249afe852daeebe (patch)
treea34aae1b4a3df5b3246dadd4b8f0a14f6e2d8e34 /src/gui/inputmethod/qcoefepinputcontext_s60.cpp
parentb85f6a46650774e2422ab44f1f12751ada8d9373 (diff)
Fix crashes in QApplication autotest
1) Input methods caused crash due to using CCoeEnv::Fep() without checking for NULL pointer 2) Autotest itself had Q_ASSERT where it should have used Q_VERIFY Reviewed-by: axis
Diffstat (limited to 'src/gui/inputmethod/qcoefepinputcontext_s60.cpp')
-rw-r--r--src/gui/inputmethod/qcoefepinputcontext_s60.cpp8
1 files changed, 6 insertions, 2 deletions
diff --git a/src/gui/inputmethod/qcoefepinputcontext_s60.cpp b/src/gui/inputmethod/qcoefepinputcontext_s60.cpp
index b198ae1d12..fc55a0fcb8 100644
--- a/src/gui/inputmethod/qcoefepinputcontext_s60.cpp
+++ b/src/gui/inputmethod/qcoefepinputcontext_s60.cpp
@@ -98,7 +98,9 @@ QCoeFepInputContext::~QCoeFepInputContext()
void QCoeFepInputContext::reset()
{
- CCoeEnv::Static()->Fep()->CancelTransaction();
+ CCoeFep* fep = CCoeEnv::Static()->Fep();
+ if (fep)
+ fep->CancelTransaction();
}
void QCoeFepInputContext::ReportAknEdStateEvent(MAknEdStateObserver::EAknEdwinStateEvent aEventType)
@@ -626,7 +628,9 @@ void QCoeFepInputContext::commitCurrentString(bool triggeredBySymbian)
m_isEditing = false;
if (!triggeredBySymbian) {
- CCoeEnv::Static()->Fep()->CancelTransaction();
+ CCoeFep* fep = CCoeEnv::Static()->Fep();
+ if (fep)
+ fep->CancelTransaction();
}
}