Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
codacy
authorMartin Quinson <martin.quinson@loria.fr>
Sun, 8 Oct 2017 16:44:31 +0000 (18:44 +0200)
committerMartin Quinson <martin.quinson@loria.fr>
Sun, 8 Oct 2017 16:44:31 +0000 (18:44 +0200)
src/surf/network_constant.cpp

index dcbc87f..1f97acc 100644 (file)
@@ -66,8 +66,8 @@ void NetworkConstantModel::updateActionsState(double /*now*/, double delta)
     if (action->getMaxDuration() != NO_MAX_DURATION)
       action->updateMaxDuration(delta);
 
-    if (((action->getRemainsNoUpdate() <= 0) ||
-         ((action->getMaxDuration() != NO_MAX_DURATION) && (action->getMaxDuration() <= 0)))) {
+    if ((action->getRemainsNoUpdate() <= 0) ||
+        ((action->getMaxDuration() != NO_MAX_DURATION) && (action->getMaxDuration() <= 0))) {
       action->finish(Action::State::done);
     }
   }