X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/blobdiff_plain/0c54495555dec7f8be37511e762e6120b8d80c7c..9121f87db72ee514f1ecc706cf7c314b1d3f8a9e:/examples/smpi/replay/replay.c diff --git a/examples/smpi/replay/replay.c b/examples/smpi/replay/replay.c index 078385a595..fb0e9f9577 100644 --- a/examples/smpi/replay/replay.c +++ b/examples/smpi/replay/replay.c @@ -28,9 +28,12 @@ int main(int argc, char *argv[]) { xbt_replay_action_register("blah", action_blah); /* The send action is an override, so we have to first save its previous value in a global */ - previous_send = xbt_replay_action_get("send"); - xbt_replay_action_register("send", overriding_send); - + int rank; + MPI_Comm_rank(MPI_COMM_WORLD, &rank); + if (rank == 0) { + previous_send = xbt_replay_action_get("send"); + xbt_replay_action_register("send", overriding_send); + } /* The regular run of the replayer */ smpi_replay_main(&argc, &argv); return 0;