Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
[action replay] check second optional parameter before parsing datatype in gatherv
authorLucas Mello Schnorr <schnorr@inf.ufrgs.br>
Tue, 19 Jan 2016 10:55:03 +0000 (08:55 -0200)
committerLucas Mello Schnorr <schnorr@inf.ufrgs.br>
Tue, 19 Jan 2016 10:55:03 +0000 (08:55 -0200)
src/smpi/smpi_replay.c

index 3c3c922..bee8307 100644 (file)
@@ -756,7 +756,7 @@ static void action_gatherv(const char *const *action) {
   int i=0,recv_sum=0;
 
   MPI_Datatype MPI_CURRENT_TYPE2;
-  if(action[4+comm_size]) {
+  if(action[4+comm_size] && action[5+comm_size]) {
     MPI_CURRENT_TYPE=decode_datatype(action[4+comm_size]);
     MPI_CURRENT_TYPE2=decode_datatype(action[5+comm_size]);
   } else {