Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Make it clearer that there's no memory leak here.
[simgrid.git] / teshsuite / smpi / macro-sample / macro-sample.c
index 4ae5dbad95cdd4036ca3b22283354a23169cf28f..e1a4bf7edddad19c58a1f9aa943ade1668a708b0 100644 (file)
@@ -48,7 +48,8 @@ int main(int argc, char *argv[])
     /* I want the standard error to go below 0.1 second.
      * Two tests at least will be run (count is not > 0) */
     SMPI_SAMPLE_LOCAL(0, 0.1) {
     /* I want the standard error to go below 0.1 second.
      * Two tests at least will be run (count is not > 0) */
     SMPI_SAMPLE_LOCAL(0, 0.1) {
-      if (verbose || n++ < 2) {
+      if (verbose || n < 2) {
+        n++;
         if (verbose)
           fprintf(stderr, "(%12.6f)", MPI_Wtime());
         else
         if (verbose)
           fprintf(stderr, "(%12.6f)", MPI_Wtime());
         else