aboutsummaryrefslogtreecommitdiff
path: root/src/Write2D.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/Write2D.c')
-rw-r--r--src/Write2D.c8
1 files changed, 3 insertions, 5 deletions
diff --git a/src/Write2D.c b/src/Write2D.c
index 32c8642..a60dc1c 100644
--- a/src/Write2D.c
+++ b/src/Write2D.c
@@ -136,7 +136,7 @@ int IOASCII_Write2D (const cGH *GH, int vindex, const char *alias)
int extent_int[3];
CCTK_INT mapping;
CCTK_REAL offset[2];
- CCTK_INT vindices[3], origin[3], extent[3], direction[6], hsize[2];
+ CCTK_INT vindices[3], origin[3], extent[2], direction[6], hsize[2];
void *hdata[3];
FILE **fileset;
DECLARE_CCTK_PARAMETERS
@@ -242,10 +242,8 @@ int IOASCII_Write2D (const cGH *GH, int vindex, const char *alias)
}
/* set the extent vector */
- for (i = 0; i < 3; i++)
- {
- extent[i] = extent_int[i];
- }
+ extent[0] = extent_int[dir_i];
+ extent[1] = extent_int[dir_j];
/* set the origin using the slice center from IOUtil */
memset (origin, 0, sizeof (origin));