- unsigned int myid = simgrid::s4u::Actor::self()->getPid() - 1;
- if ((comm->group()->actor(dst)->getPid()-1 == myid) && (comm->group()->actor(src)->getPid()-1 == myid)){
- Datatype::copy(sendbuf, sendcount, sendtype, recvbuf, recvcount, recvtype);
- return;
+ int myid = simgrid::s4u::this_actor::get_pid();
+ if ((comm->group()->actor(dst)->get_pid() == myid) && (comm->group()->actor(src)->get_pid() == myid)) {
+ Datatype::copy(sendbuf, sendcount, sendtype, recvbuf, recvcount, recvtype);
+ if (status != MPI_STATUS_IGNORE) {
+ status->MPI_SOURCE = src;
+ status->MPI_TAG = recvtag;
+ status->MPI_ERROR = MPI_SUCCESS;
+ status->count = sendcount * sendtype->size();
+ }
+ return;