Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Add some _XBT_GNUC_UNUSED to avoid compilation warnings with NDEBUG
[simgrid.git] / examples / msg / parallel_task / test_ptask.c
index 80fe67b..03c5b94 100644 (file)
@@ -49,7 +49,7 @@ int execute(int argc, char *argv[])
                 "Unknown host %s. Stopping Now! ", argv[i]);
   }
 
-  int read;
+  _XBT_GNUC_UNUSED int read;
   read = sscanf(argv[argc - 2], "%lg", &computation_amount);
   xbt_assert(read, "Invalid argument %s\n", argv[argc - 2]);
   read = sscanf(argv[argc - 1], "%lg", &communication_amount);
@@ -105,7 +105,7 @@ int redistribute(int argc, char *argv[])
                 "Unknown host %s. Stopping Now! ", argv[i]);
   }
 
-  int read;
+  _XBT_GNUC_UNUSED int read;
   read = sscanf(argv[argc - 1], "%lg", &communication_amount);
   xbt_assert(read, "Invalid argument %s\n", argv[argc - 1]);
   computation_duration = (double *) calloc(host_list_size, sizeof(double));