Skip to content
Snippets Groups Projects
Commit 28a17195 authored by Rene Halver's avatar Rene Halver
Browse files

added check to prevent to free MPI_COMM_SELF or MPI_COMM_WORLD

parent 3d92c30e
No related branches found
No related tags found
No related merge requests found
Pipeline #24584 failed
......@@ -391,7 +391,10 @@ template<class T, class W> void ALL_Histogram_LB<T,W>::balance(int step)
MPI_Barrier(this->global_comm);
// free created communicators
for (int i = 0; i < 6; ++i)
{
if (communicators.at(i) != MPI_COMM_SELF && communicators.at(i) != MPI_COMM_WORLD)
MPI_Comm_free(&(communicators.at(i)));
}
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment