X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/blobdiff_plain/86ad7bacaf8c0b206a62bf87193ca6800006a854..c897fb0d193bbe081581d7ea7f579f04df1b5b5d:/src/xbt/xbt_replay.cpp diff --git a/src/xbt/xbt_replay.cpp b/src/xbt/xbt_replay.cpp index b9b6612af1..74bc5a3f71 100644 --- a/src/xbt/xbt_replay.cpp +++ b/src/xbt/xbt_replay.cpp @@ -78,9 +78,9 @@ static ReplayAction* get_action(char* name) } else { // Else, I have to store it for the relevant colleague std::queue* otherqueue = nullptr; - if (action_queues.find(evtname) != action_queues.end()) + try { otherqueue = action_queues.at(evtname); - else { // Damn. Create the queue of that guy + } catch (std::out_of_range& unfound) { // Damn. Create the queue of that guy otherqueue = new std::queue(); action_queues.insert({evtname, otherqueue}); }