Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Please sonar.
authordegomme <augustin.degomme@unibas.ch>
Tue, 14 Feb 2017 11:35:56 +0000 (12:35 +0100)
committerdegomme <augustin.degomme@unibas.ch>
Tue, 14 Feb 2017 11:39:09 +0000 (12:39 +0100)
Is this really what we want ?

src/smpi/smpi_mpi_dt.cpp

index 9bd0d52..8c63b07 100644 (file)
@@ -1403,7 +1403,8 @@ void smpi_op_apply(MPI_Op op, void *invec, void *inoutvec, int *len, MPI_Datatyp
       op->func(invec, inoutvec, len, datatype);
     else{
       int tmp = smpi_type_c2f(*datatype);
-      op->func(invec, inoutvec, len, reinterpret_cast<MPI_Datatype*>(&tmp) );
+      void* tmpptr=static_cast<void*>(&tmp);
+      op->func(invec, inoutvec, len, static_cast<MPI_Datatype*>(tmpptr) );
     }
   }
 }