Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
[sonar] Constify pointer and reference local variables in src/xbt/.
[simgrid.git] / src / xbt / xbt_replay.cpp
index 7af9758..cb966e9 100644 (file)
@@ -102,7 +102,7 @@ static void handle_action(ReplayAction& action)
   action_fun function = action_funs.at(action.at(1));
   try {
     function(action);
-  } catch (xbt_ex& e) {
+  } catch (const Exception& e) {
     action.clear();
     xbt_die("Replay error:\n %s", e.what());
   }
@@ -124,8 +124,7 @@ int replay_runner(const char* actor_name, const char* trace_filename)
       delete evt;
     }
     if (action_queues.find(actor_name_string) != action_queues.end()) {
-      std::queue<ReplayAction*>* myqueue = action_queues.at(actor_name_string);
-      delete myqueue;
+      delete action_queues.at(actor_name_string);
       action_queues.erase(actor_name_string);
     }
   } else { // Should have got my trace file in argument