Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
sed -i -e 's/\t/ /g' *.[ch] Please people, stop using tabs in your source
[simgrid.git] / examples / msg / mc / centralized_liveness.c
index b1438e2..395d4c2 100644 (file)
@@ -1,6 +1,6 @@
 /***************** Centralized Mutual Exclusion Algorithm *********************/
 /* This example implements a centralized mutual exclusion algorithm.          */
-/* LTL property checked : !(GFcs)                                                                                                                                                      */
+/* LTL property checked : !(GFcs)                                            */
 /******************************************************************************/
 
 #include "msg/msg.h"
@@ -32,7 +32,7 @@ int coordinator(int argc, char *argv[])
       char *req = MSG_task_get_data(task);
       if (CS_used) { 
         XBT_INFO("CS already used.");
-       m_task_t answer = MSG_task_create("not grant", 0, 1000, NULL);
+  m_task_t answer = MSG_task_create("not grant", 0, 1000, NULL);
         MSG_task_send(answer, req);
       } else {                  // can serve it immediatly
         XBT_INFO("CS idle. Grant immediatly");
@@ -72,15 +72,15 @@ int client(int argc, char *argv[])
       XBT_INFO("Client (%s) got the answer (grant). Sleep a bit and release it", my_mailbox);
 
       if(!strcmp(my_mailbox, "1"))
-       cs = 1;
+  cs = 1;
 
       /*MSG_process_sleep(my_pid);
       MSG_task_send(MSG_task_create("release", 0, 1000, NULL),
-                   "coordinator");
-                   XBT_INFO("Client (%s) releases the CS", my_mailbox);
+        "coordinator");
+        XBT_INFO("Client (%s) releases the CS", my_mailbox);
       
       if(!strcmp(my_mailbox, "1"))
-       cs = 0;*/
+  cs = 0;*/
       
     }else{