aboutsummaryrefslogtreecommitdiffstats
path: root/src/qml/jsruntime
diff options
context:
space:
mode:
authorLars Knoll <[email protected]>2013-10-22 10:48:21 +0200
committerThe Qt Project <[email protected]>2013-10-29 10:38:57 +0100
commit2b996ca17fbc36029af3900933b6fcc1418afb6a (patch)
tree1c3712947febfedc5bb5566053ab0e7093eeabc6 /src/qml/jsruntime
parente0284ab41f7a1889f28e719212df66e942959f4c (diff)
Correctly catch exceptions in the API methods
Replace all C++ try/catch statements with engine->hasException checks. Change-Id: I7c04e02664ec6b4d256478c6e18f6b20ae4f7bc1 Reviewed-by: Simon Hausmann <[email protected]>
Diffstat (limited to 'src/qml/jsruntime')
-rw-r--r--src/qml/jsruntime/qv4scopedvalue_p.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/qml/jsruntime/qv4scopedvalue_p.h b/src/qml/jsruntime/qv4scopedvalue_p.h
index 2e76eb453e..0465cd72c5 100644
--- a/src/qml/jsruntime/qv4scopedvalue_p.h
+++ b/src/qml/jsruntime/qv4scopedvalue_p.h
@@ -86,6 +86,10 @@ struct Scope {
return ptr;
}
+ bool hasException() const {
+ return engine->hasException;
+ }
+
ExecutionEngine *engine;
SafeValue *mark;
#ifndef QT_NO_DEBUG