From b025babfec365985fd4b6e3169f7dd9ea9a8c04f Mon Sep 17 00:00:00 2001 From: Nathan Hjelm Date: Fri, 4 Oct 2013 17:34:54 +0000 Subject: [PATCH] Correctly set the state for communicator requests. Refs trac:3796 This commit was SVN r29377. The following Trac tickets were found above: Ticket 3796 --> https://svn.open-mpi.org/trac/ompi/ticket/3796 --- ompi/communicator/comm_request.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/ompi/communicator/comm_request.c b/ompi/communicator/comm_request.c index c691a728cc..7be1f333f9 100644 --- a/ompi/communicator/comm_request.c +++ b/ompi/communicator/comm_request.c @@ -155,6 +155,8 @@ void ompi_comm_request_start (ompi_comm_request_t *request) ompi_comm_request_progress_active = true; } + request->super.req_state = OMPI_REQUEST_ACTIVE; + opal_mutex_unlock (&ompi_comm_request_mutex); } @@ -195,7 +197,7 @@ static int ompi_comm_request_free (struct ompi_request_t **ompi_req) return MPI_ERR_REQUEST; } - (*ompi_req)->req_complete = false; + OMPI_REQUEST_FINI(*ompi_req); ompi_comm_request_return (request); *ompi_req = MPI_REQUEST_NULL; @@ -233,6 +235,8 @@ ompi_comm_request_t *ompi_comm_request_get (void) OPAL_FREE_LIST_GET(&ompi_comm_requests, item, rc); (void) rc; + OMPI_REQUEST_INIT((ompi_request_t *) item, false); + return (ompi_comm_request_t *) item; }