From 5d06aefbecef1a2944cdd63fb6e6c846ea8c19db Mon Sep 17 00:00:00 2001 From: Jon Walsh Date: Mon, 4 Aug 2014 21:43:21 -0600 Subject: [PATCH] threadsafe particle restart writing --- src/particle_restart_write.F90 | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/particle_restart_write.F90 b/src/particle_restart_write.F90 index ba22d19d0e..f76537aa38 100644 --- a/src/particle_restart_write.F90 +++ b/src/particle_restart_write.F90 @@ -38,6 +38,7 @@ contains filename = trim(filename) // '.binary' #endif +!$omp critical ! Create file call pr % file_create(filename) @@ -59,6 +60,7 @@ contains ! Close file call pr % file_close() +!$omp end critical end subroutine write_particle_restart