if (is_on()) {
Resource::turn_off();
s4u::Disk::on_state_change(piface_);
+
+ const kernel::lmm::Element* elem = nullptr;
+ double now = EngineImpl::get_clock();
+ while (const auto* var = get_constraint()->get_variable(&elem)) {
+ Action* action = var->get_id();
+ if (action->get_state() == Action::State::INITED || action->get_state() == Action::State::STARTED) {
+ action->set_finish_time(now);
+ action->set_state(Action::State::FAILED);
+ }
+ }
}
}