diff options
author | Kent Hansen <khansen@trolltech.com> | 2009-06-17 12:57:23 (GMT) |
---|---|---|
committer | Kent Hansen <khansen@trolltech.com> | 2009-06-17 13:03:40 (GMT) |
commit | abc67ad77fa719db95254ac2995c0ce1a3ebaf5c (patch) | |
tree | 70cc9e259e77e95839942025996dd4fce9655404 /tests/auto/qscriptenginedebugger | |
parent | f10441ab65d6204f23735e7cffbab5ac81663e91 (diff) | |
download | Qt-abc67ad77fa719db95254ac2995c0ce1a3ebaf5c.zip Qt-abc67ad77fa719db95254ac2995c0ce1a3ebaf5c.tar.gz Qt-abc67ad77fa719db95254ac2995c0ce1a3ebaf5c.tar.bz2 |
reset debugger's state correctly when previous engine was deleted
If the engine was deleted, the agent will be 0, but we still
want to fall through rather than return immediately, so that
the other variables are reset correctly.
Diffstat (limited to 'tests/auto/qscriptenginedebugger')
-rw-r--r-- | tests/auto/qscriptenginedebugger/tst_qscriptenginedebugger.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/tests/auto/qscriptenginedebugger/tst_qscriptenginedebugger.cpp b/tests/auto/qscriptenginedebugger/tst_qscriptenginedebugger.cpp index 7f3f9f3..5e5b701 100644 --- a/tests/auto/qscriptenginedebugger/tst_qscriptenginedebugger.cpp +++ b/tests/auto/qscriptenginedebugger/tst_qscriptenginedebugger.cpp @@ -163,6 +163,14 @@ void tst_QScriptEngineDebugger::attachAndDetach() debugger2.attachTo(&engine); } #endif + { + QScriptEngine *engine = new QScriptEngine; + QScriptEngineDebugger debugger; + debugger.attachTo(engine); + delete engine; + QScriptEngine engine2; + debugger.attachTo(&engine2); + } } void tst_QScriptEngineDebugger::action() |