Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
leaks --
authordegomme <augustin.degomme@unibas.ch>
Thu, 21 Apr 2016 09:19:40 +0000 (11:19 +0200)
committerdegomme <augustin.degomme@unibas.ch>
Thu, 21 Apr 2016 09:26:02 +0000 (11:26 +0200)
src/smpi/smpi_base.cpp

index cd003cd..687a6d8 100644 (file)
@@ -693,9 +693,9 @@ static void finish_wait(MPI_Request * request, MPI_Status * status)
       }
     }
     smpi_comm_unuse(req->comm);
       }
     }
     smpi_comm_unuse(req->comm);
+    smpi_datatype_unuse(req->old_type);
   }
 
   }
 
-    smpi_datatype_unuse(req->old_type);
   if (TRACE_smpi_view_internals()) {
     if(req->flags & RECV){
       int rank = smpi_process_index();
   if (TRACE_smpi_view_internals()) {
     if(req->flags & RECV){
       int rank = smpi_process_index();
@@ -705,6 +705,8 @@ static void finish_wait(MPI_Request * request, MPI_Status * status)
   }
 
   if(req->detached_sender!=NULL){
   }
 
   if(req->detached_sender!=NULL){
+    smpi_datatype_unuse(req->detached_sender->old_type);
+    smpi_comm_unuse(req->detached_sender->comm);
     smpi_mpi_request_free(&(req->detached_sender));
   }
   if(req->flags & PERSISTENT)
     smpi_mpi_request_free(&(req->detached_sender));
   }
   if(req->flags & PERSISTENT)