diff options
author | tradke <tradke@b61c5cb5-eaca-4651-9a7a-d64986f99364> | 2004-06-29 09:39:17 +0000 |
---|---|---|
committer | tradke <tradke@b61c5cb5-eaca-4651-9a7a-d64986f99364> | 2004-06-29 09:39:17 +0000 |
commit | 5a040e2ea7b4fbc6b24377d37707324b45a3534c (patch) | |
tree | 2e3ba3f75b089c5e2fb2d8e9a3ae8c6634d3957f /src | |
parent | 6046e1ba82096437d6bed4ade54e8358e1ff12db (diff) |
Fix for my last commit: destroy groups in ascending order.
git-svn-id: http://svn.cactuscode.org/arrangements/CactusPUGH/PUGH/trunk@449 b61c5cb5-eaca-4651-9a7a-d64986f99364
Diffstat (limited to 'src')
-rw-r--r-- | src/SetupPGH.c | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/src/SetupPGH.c b/src/SetupPGH.c index b14088e..8a6882b 100644 --- a/src/SetupPGH.c +++ b/src/SetupPGH.c @@ -219,10 +219,7 @@ void PUGH_DestroyPGH (pGH **GHin) pGH *GH; pGA *GA; cGroup pgroup; - int i; - int variable; - int group; - int this_var; + int i, group, numgroups, this_var, variable; GH = *GHin; @@ -244,7 +241,8 @@ void PUGH_DestroyPGH (pGH **GHin) /* Great. Now go about the work of destroying me. */ variable = 0; - for (group = CCTK_NumGroups () - 1; group >= 0; group--) + numgroups = CCTK_NumGroups (); + for (group = 0; group < numgroups; group++) { #ifdef DEBUG_PUGH printf ("Calling Destroying Group %s\n", CCTK_GroupName (group)); |