diff options
Diffstat (limited to 'src/Output1D.c')
-rw-r--r-- | src/Output1D.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/src/Output1D.c b/src/Output1D.c index b0e73c5..b780e26 100644 --- a/src/Output1D.c +++ b/src/Output1D.c @@ -117,8 +117,12 @@ int IOASCII_Output1DVarAs (const cGH *GH, const char *fullname, const char *alia retval = -1; vindex = CCTK_VarIndex (fullname); - - if (CheckOutputVar (vindex)) + if (vindex<0) + { + CCTK_VWarn (1, __LINE__, __FILE__, CCTK_THORNSTRING, + "There is no such variable %s. Ignoring IOASCII 1D output.", + fullname); + } else if (CheckOutputVar (vindex)) { retval = IOASCII_Write1D (GH, vindex, alias); } |