diff options
Diffstat (limited to 'src/Write2D.c')
-rw-r--r-- | src/Write2D.c | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/src/Write2D.c b/src/Write2D.c index 2906c79..5681f7d 100644 --- a/src/Write2D.c +++ b/src/Write2D.c @@ -113,9 +113,13 @@ int IOSDF_Write2D (const cGH *GH, int vindex, const char *alias) maxdir = gdata.dim == 2 ? 1 : 3; /* get the coordinate system associated with this grid variable */ - groupname = CCTK_GroupName (gindex); - coord_system_handle = Coord_GroupSystem (GH, groupname); - free (groupname); + coord_system_handle = -1; + if (CCTK_IsFunctionAliased ("Coord_GroupSystem")) + { + groupname = CCTK_GroupName (gindex); + coord_system_handle = Coord_GroupSystem (GH, groupname); + free (groupname); + } dir = gdata.dim < 3 ? gdata.dim : 3; |