summaryrefslogtreecommitdiffstats
path: root/src/uscxml/interpreter/InterpreterDraft6.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/uscxml/interpreter/InterpreterDraft6.cpp')
-rw-r--r--src/uscxml/interpreter/InterpreterDraft6.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/uscxml/interpreter/InterpreterDraft6.cpp b/src/uscxml/interpreter/InterpreterDraft6.cpp
index 8be2634..12d6123 100644
--- a/src/uscxml/interpreter/InterpreterDraft6.cpp
+++ b/src/uscxml/interpreter/InterpreterDraft6.cpp
@@ -121,7 +121,8 @@ NodeSet<std::string> InterpreterDraft6::getDocumentInitialTransitions() {
// a macrostep
InterpreterState InterpreterDraft6::step(bool blocking) {
try {
-
+ tthread::lock_guard<tthread::recursive_mutex> lock(_mutex);
+
monIter_t monIter;
NodeSet<std::string> enabledTransitions;
@@ -147,6 +148,7 @@ InterpreterState InterpreterDraft6::step(bool blocking) {
// read an external event and react
if (blocking) {
+
// wait until an event becomes available
while(_externalQueue.isEmpty()) {
_condVar.wait(_mutex);