diff options
Diffstat (limited to 'Carpet')
-rw-r--r-- | Carpet/CarpetIOHDF5/src/CarpetIOHDF5.cc | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/Carpet/CarpetIOHDF5/src/CarpetIOHDF5.cc b/Carpet/CarpetIOHDF5/src/CarpetIOHDF5.cc index fc96024d6..da55245dc 100644 --- a/Carpet/CarpetIOHDF5/src/CarpetIOHDF5.cc +++ b/Carpet/CarpetIOHDF5/src/CarpetIOHDF5.cc @@ -525,14 +525,6 @@ static int OutputVarAs (const cGH* const cctkGH, const char* const fullname, assert (do_global_mode); } - // Check for storage - if (not CCTK_QueryGroupStorageI (cctkGH, group)) { - CCTK_VWarn (1, __LINE__, __FILE__, CCTK_THORNSTRING, - "Cannot output variable '%s' because it has no storage", - fullname); - return (0); - } - // get the default I/O request for this variable const CarpetIOHDF5GH *myGH = (CarpetIOHDF5GH *) CCTK_GHExtension (cctkGH, CCTK_THORNSTRING); @@ -600,6 +592,14 @@ static int OutputVarAs (const cGH* const cctkGH, const char* const fullname, assert (last_output < cctk_iteration); last_output = cctk_iteration; + // Check for storage + if (not CCTK_QueryGroupStorageI (cctkGH, group)) { + CCTK_VWarn (1, __LINE__, __FILE__, CCTK_THORNSTRING, + "Cannot output variable '%s' because it has no storage", + fullname); + return (0); + } + // Open the output file if this is a designated I/O processor hid_t file = -1; if (dist::rank() == ioproc) { |