Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
try to clean and uniformize Activity Impls
[simgrid.git] / src / kernel / actor / ActorImpl.cpp
index 53caa70..dabf488 100644 (file)
@@ -371,7 +371,9 @@ activity::ActivityImplPtr ActorImpl::suspend(ActorImpl* issuer)
 
     return nullptr;
   } else {
-    return activity::ExecImplPtr(new activity::ExecImpl())->set_name("suspend")->set_host(host_)->start(0.0, 1.0, 0.0);
+    activity::ExecImpl* exec = new activity::ExecImpl();
+    (*exec).set_name("suspend").set_host(host_).start(0.0, 1.0, 0.0);
+    return activity::ExecImplPtr(exec);
   }
 }