summaryrefslogtreecommitdiffstats
path: root/src/script/api/qscriptengine_p.h
diff options
context:
space:
mode:
authorThomas McGuire <thomas.mcguire.qnx@kdab.com>2012-08-15 07:50:47 (GMT)
committerQt by Nokia <qt-info@nokia.com>2012-09-14 11:33:45 (GMT)
commitecc432a5b7ae269220f86c6f0b3dd364f8643191 (patch)
tree66c9f0ecc280d9b71e677266f533ce9edafa0f94 /src/script/api/qscriptengine_p.h
parent3414828ccc91da0d94f3b160f29766b9273357ad (diff)
downloadQt-ecc432a5b7ae269220f86c6f0b3dd364f8643191.zip
Qt-ecc432a5b7ae269220f86c6f0b3dd364f8643191.tar.gz
Qt-ecc432a5b7ae269220f86c6f0b3dd364f8643191.tar.bz2
Delete JS-owned QML objects right away in the engine dtor.
This prevents memory leaks when the engine is destroyed after exec() has already finished. In most cases this happens during application shutdown, at which point the event loop is never entered again. Task-number: QTBUG-20377 Change-Id: I65564ed3e56314d656d92fd66f11ae67d4eb932b Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@nokia.com> Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
Diffstat (limited to 'src/script/api/qscriptengine_p.h')
-rw-r--r--src/script/api/qscriptengine_p.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/script/api/qscriptengine_p.h b/src/script/api/qscriptengine_p.h
index 6a023d7..8a7037b 100644
--- a/src/script/api/qscriptengine_p.h
+++ b/src/script/api/qscriptengine_p.h
@@ -382,6 +382,7 @@ public:
int processEventsInterval;
QScriptValue abortResult;
bool inEval;
+ bool inDestructor;
JSC::UString cachedTranslationUrl;
JSC::UString cachedTranslationContext;