Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Fix some conflicts with modifications introduced in the svn branch
[simgrid.git] / src / msg / msg_mailbox.c
index 0164422..8c1cb6d 100644 (file)
@@ -110,7 +110,6 @@ MSG_mailbox_get_task_ext(msg_mailbox_t mailbox, m_task_t *task, m_host_t host,
 {
   xbt_ex_t e;
   MSG_error_t ret = MSG_OK;
-  size_t buff_size = 0;
   smx_comm_t comm;
   CHECK_HOST();
 
@@ -132,7 +131,7 @@ MSG_mailbox_get_task_ext(msg_mailbox_t mailbox, m_task_t *task, m_host_t host,
 
   /* Try to receive it by calling SIMIX network layer */
   TRY{
-    SIMIX_network_recv(mailbox->rdv, timeout, NULL, &buff_size, &comm);
+    SIMIX_network_recv(mailbox->rdv, timeout, NULL, NULL, &comm);
   }
   CATCH(e){
     switch(e.category){
@@ -152,7 +151,7 @@ MSG_mailbox_get_task_ext(msg_mailbox_t mailbox, m_task_t *task, m_host_t host,
   }
 
   *task = SIMIX_communication_get_data(comm);
-
+  
   /* If the sender didn't decremented the refcount so far then do it */
   if (*task && (*task)->simdata->refcount > 1)
     (*task)->simdata->refcount--;
@@ -183,7 +182,7 @@ MSG_mailbox_put_with_timeout(msg_mailbox_t mailbox, m_task_t task,
   msg_global->sent_msg++;
 
   process->simdata->waiting_task = task;
-
+  
   /* Try to send it by calling SIMIX network layer */
   TRY{
     /* Kept for semantical compatibility with older implementation */
@@ -209,13 +208,10 @@ MSG_mailbox_put_with_timeout(msg_mailbox_t mailbox, m_task_t task,
         xbt_die("Unhandled SIMIX network exception");
     }
     xbt_ex_free(e);
-    /* If the receiver end didn't decremented the refcount so far then do it */
-    if (t_simdata->refcount > 1)
-      t_simdata->refcount--;
   }
 
   process->simdata->waiting_task = NULL;
-
+  
   /* If the receiver end didn't decremented the refcount so far then do it */
   if (t_simdata->refcount > 1)
     t_simdata->refcount--;