BUG: changed setting of the _running flag in WorkflowEngineLoop

It is now set in the constructor, and not changed in start_loop(), to avoid race condition when the loop is stopped immediately, and before the loop thread actually starts.