Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Use a fifo instead of a swag of sleeping processes on a semaphore (so that waitany...
[simgrid.git] / src / simix / smx_process.c
index 97296a1..3d080f2 100644 (file)
@@ -164,7 +164,7 @@ void SIMIX_process_kill(smx_process_t process)
     }
 
     if (process->sem) {
-      xbt_swag_remove(process, process->sem->sleeping);
+      xbt_fifo_remove(process->sem->sleeping, process);
 
       if (process->waiting_action) {
         SIMIX_unregister_action_to_semaphore(process->waiting_action, process->sem);
@@ -196,7 +196,7 @@ void SIMIX_process_kill(smx_process_t process)
     }
 
     if (process->sem) {
-       xbt_swag_remove(process, process->sem->sleeping);
+      xbt_fifo_remove(process->sem->sleeping, process);
 
       if (process->waiting_action) {
        SIMIX_unregister_action_to_semaphore(process->waiting_action, process->sem);