From: Arnaud Giersch Date: Sun, 22 Oct 2017 15:44:51 +0000 (+0200) Subject: Sonar smell. X-Git-Tag: v3.18~399^2 X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/commitdiff_plain/0c766ee764cfc61c30df4a263bab662b124cbd57?hp=-c Sonar smell. --- 0c766ee764cfc61c30df4a263bab662b124cbd57 diff --git a/src/kernel/context/ContextUnix.cpp b/src/kernel/context/ContextUnix.cpp index 7ddae022aa..fd6562f6cf 100644 --- a/src/kernel/context/ContextUnix.cpp +++ b/src/kernel/context/ContextUnix.cpp @@ -253,7 +253,8 @@ void SerialUContext::suspend() { /* determine the next context */ UContext* next_context = nullptr; - unsigned long int i = sysv_process_index++; + unsigned long int i = sysv_process_index; + sysv_process_index++; if (i < simix_global->process_to_run.size()) { /* execute the next process */