diff options
-rw-r--r-- | src/CheckpointRecovery.c | 16 |
1 files changed, 12 insertions, 4 deletions
diff --git a/src/CheckpointRecovery.c b/src/CheckpointRecovery.c index b42414e..a92f13d 100644 --- a/src/CheckpointRecovery.c +++ b/src/CheckpointRecovery.c @@ -848,6 +848,7 @@ void IOUtil_SetAllParameters (const char *parameters) char oldchar; char *name, *thorn_impl, *parameter_string, *free_me; const char *thorn; + const cParamData *paramdata; DECLARE_CCTK_PARAMETERS @@ -882,12 +883,19 @@ void IOUtil_SetAllParameters (const char *parameters) thorn = thorn_impl; } - /* set parameter only if it belongs to an active implementation */ + /* set parameter only if it belongs to an active implementation + and is not an accumulator parameter */ if (CCTK_IsThornActive (thorn)) { - if (CCTK_ParameterSet (name, thorn, avalue) < 0) - CCTK_VWarn (2, __LINE__, __FILE__, CCTK_THORNSTRING, - "Couldn't set parameter '%s' to '%s'", param, avalue); + paramdata = CCTK_ParameterData (name, thorn); + if (paramdata && ! paramdata->accumulator_expression) + { + if (CCTK_ParameterSet (name, thorn, avalue) < 0) + { + CCTK_VWarn (2, __LINE__, __FILE__, CCTK_THORNSTRING, + "Couldn't set parameter '%s' to '%s'", param, avalue); + } + } } else if (CCTK_Equals (verbose, "full")) { |