aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/Overloadables.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/Overloadables.c b/src/Overloadables.c
index 141c6fa..210d65b 100644
--- a/src/Overloadables.c
+++ b/src/Overloadables.c
@@ -51,6 +51,7 @@ int PUGHi_NumTimeLevelsArray(const pGH *pughGH, int var, int timelevels);
0 for success <BR>
-1 if given pointer to data structure is NULL <BR>
-3 if given GH pointer is invalid
+ -77 if group has zero variables
@endreturndesc
@@*/
int PUGH_GroupDynamicData (const cGH *GH, int group, cGroupDynamicData *data)
@@ -66,6 +67,11 @@ int PUGH_GroupDynamicData (const cGH *GH, int group, cGroupDynamicData *data)
gtype = CCTK_GroupTypeI (group);
/* Get the first variable in the group */
var = CCTK_FirstVarIndexI (group);
+ if (var<0)
+ {
+ retval = -77;
+ return retval;
+ }
pughGH = PUGH_pGH (GH);
if (pughGH)