Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
model-checker : fix centralized mutex example
authorMarion Guthmuller <marion.guthmuller@loria.fr>
Wed, 2 Oct 2013 14:18:06 +0000 (16:18 +0200)
committerMarion Guthmuller <marion.guthmuller@loria.fr>
Fri, 4 Oct 2013 13:21:19 +0000 (15:21 +0200)
examples/msg/mc/centralized_mutex.c

index 64008b4..3403c88 100644 (file)
@@ -45,7 +45,7 @@ int coordinator(int argc, char *argv[])
         XBT_INFO("CS release. Grant to queued requests (queue size: %lu)",
               xbt_dynar_length(requests));
         char *req;
-        xbt_dynar_pop(requests, &req);
+        xbt_dynar_shift(requests, &req);
         MSG_task_send(MSG_task_create("grant", 0, 1000, NULL), req);
         todo--;
       } else {                  // nobody wants it