Browse Source

shut up static analyzers which can not see that the array gets initialized by the loop

Samuel Thibault 7 years ago
parent
commit
e727596335
1 changed files with 1 additions and 1 deletions
  1. 1 1
      mpi/src/starpu_mpi_coop_sends.c

+ 1 - 1
mpi/src/starpu_mpi_coop_sends.c

@@ -82,7 +82,7 @@ static void _starpu_mpi_submit_coop_sends(void *arg)
 	_STARPU_MPI_DEBUG(0, "handling cooperative sends %p for %u neighbours\n", coop_sends, n);
 
 	/* Store them in an array */
-	struct _starpu_mpi_req *reqs[n];
+	struct _starpu_mpi_req *reqs[n] = { NULL };
 	unsigned i;
 	for (cur  = _starpu_mpi_req_multilist_begin_coop_sends(&coop_sends->reqs), i = 0;
 	     cur != _starpu_mpi_req_multilist_end_coop_sends(&coop_sends->reqs);