Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Add an assert/fixme around Actor::set_auto_restart.
authorArnaud Giersch <arnaud.giersch@univ-fcomte.fr>
Tue, 11 Sep 2018 20:35:20 +0000 (22:35 +0200)
committerArnaud Giersch <arnaud.giersch@univ-fcomte.fr>
Tue, 11 Sep 2018 20:52:47 +0000 (22:52 +0200)
src/s4u/s4u_Actor.cpp

index 2d162da..945dfb4 100644 (file)
@@ -76,6 +76,7 @@ void Actor::join(double timeout)
 void Actor::set_auto_restart(bool autorestart)
 {
   simgrid::simix::simcall([this, autorestart]() {
 void Actor::set_auto_restart(bool autorestart)
 {
   simgrid::simix::simcall([this, autorestart]() {
+    xbt_assert(autorestart && not pimpl_->auto_restart_); // FIXME: handle all cases
     pimpl_->set_auto_restart(autorestart);
 
     simgrid::kernel::actor::ProcessArg* arg = new simgrid::kernel::actor::ProcessArg(pimpl_->host_, pimpl_);
     pimpl_->set_auto_restart(autorestart);
 
     simgrid::kernel::actor::ProcessArg* arg = new simgrid::kernel::actor::ProcessArg(pimpl_->host_, pimpl_);