Fixed infinite loop bug in Service::BeginExecuteCheck.

This commit is contained in:
Gunnar Beutner 2013-02-08 11:22:42 +01:00
parent 7526ee3a9e
commit 39008eff4e
1 changed files with 3 additions and 1 deletions

View File

@ -661,6 +661,8 @@ void Service::BeginExecuteCheck(const function<void (void)>& callback)
arguments.push_back(static_cast<Service::Ptr>(GetSelf())); arguments.push_back(static_cast<Service::Ptr>(GetSelf()));
ScriptTask::Ptr task; ScriptTask::Ptr task;
task = InvokeMethod("check", arguments, boost::bind(&Service::CheckCompletedHandler, this, scheduleInfo, _1, callback)); task = InvokeMethod("check", arguments, boost::bind(&Service::CheckCompletedHandler, this, scheduleInfo, _1, callback));
if (!task->IsFinished())
Set("current_task", task); Set("current_task", task);
} catch (...) { } catch (...) {
/* something went wrong while setting up the method call - /* something went wrong while setting up the method call -