aboutsummaryrefslogtreecommitdiff
path: root/Carpet/CarpetIOHDF5/src/CarpetIOHDF5.cc
diff options
context:
space:
mode:
authorThomas Radke <tradke@aei.mpg.de>2008-09-02 10:54:54 +0200
committerThomas Radke <tradke@aei.mpg.de>2008-09-02 10:54:54 +0200
commit3ece2c1615689ef2931d4efcb228209f13dc5638 (patch)
treec38a4951f4c017f4b43eda54dc08e2bc1c4d6ffe /Carpet/CarpetIOHDF5/src/CarpetIOHDF5.cc
parentd83ab8361cf4b93c4c4cde233ae07db201bf2d67 (diff)
Schedule the initialisation of checkpointing interval counter
variables also in the POST_RECOVER_VARIABLES bin so that the last checkpoint iteration counter starts counting from the recovered iteration number. (see also discussion thread starting at http://lists.carpetcode.org/archives/developers/2008-August/002309.html)
Diffstat (limited to 'Carpet/CarpetIOHDF5/src/CarpetIOHDF5.cc')
-rw-r--r--Carpet/CarpetIOHDF5/src/CarpetIOHDF5.cc8
1 files changed, 8 insertions, 0 deletions
diff --git a/Carpet/CarpetIOHDF5/src/CarpetIOHDF5.cc b/Carpet/CarpetIOHDF5/src/CarpetIOHDF5.cc
index 8b15338ef..753162c91 100644
--- a/Carpet/CarpetIOHDF5/src/CarpetIOHDF5.cc
+++ b/Carpet/CarpetIOHDF5/src/CarpetIOHDF5.cc
@@ -111,6 +111,14 @@ void CarpetIOHDF5_Init (CCTK_ARGUMENTS)
*next_output_time = cctk_time;
// Initialise checkpointing intervals
+ CarpetIOHDF5_InitCheckpointingIntervals (CCTK_PASS_CTOC);
+}
+
+
+void CarpetIOHDF5_InitCheckpointingIntervals (CCTK_ARGUMENTS)
+{
+ DECLARE_CCTK_ARGUMENTS;
+
last_checkpoint_iteration = cctk_iteration;
last_checkpoint_walltime = CCTK_RunTime() / 3600.0;
}