mirror of
https://github.com/openmc-dev/openmc.git
synced 2026-07-27 05:35:49 -04:00
Merge pull request #1335 from paulromano/openmpi-fix2
Better conditional for call to MPI_Type_free
This commit is contained in:
commit
5968db8cdd
1 changed files with 1 additions and 3 deletions
|
|
@ -127,9 +127,7 @@ int openmc_finalize()
|
|||
|
||||
// Free all MPI types
|
||||
#ifdef OPENMC_MPI
|
||||
int init_called;
|
||||
MPI_Initialized(&init_called);
|
||||
if (init_called) MPI_Type_free(&mpi::bank);
|
||||
if (mpi::bank != MPI_DATATYPE_NULL) MPI_Type_free(&mpi::bank);
|
||||
#endif
|
||||
|
||||
return 0;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue