diff options
author | knarf <knarf@eff87b29-5268-4891-90a3-a07138403961> | 2011-08-21 03:48:00 +0000 |
---|---|---|
committer | knarf <knarf@eff87b29-5268-4891-90a3-a07138403961> | 2011-08-21 03:48:00 +0000 |
commit | ee2b51e7a68f72d503d6a5cb507b334e705ae8fe (patch) | |
tree | b3d2a6f1ba703e576ad406649c963359e92dfe06 | |
parent | fc459ff09a5a522607e7c94c347107a3432ba251 (diff) |
patch from Steven Brandt: It gets rid of annoying error messages when one of the dimensions is one.
git-svn-id: http://svn.cactuscode.org/arrangements/CactusIO/IOJpeg/trunk@139 eff87b29-5268-4891-90a3-a07138403961
-rw-r--r-- | src/Write.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/Write.c b/src/Write.c index 4ada69b..498f5b9 100644 --- a/src/Write.c +++ b/src/Write.c @@ -154,14 +154,20 @@ int IOJpeg_Write (const cGH *GH, CCTK_INT vindex, const char *alias) if (dir == 0) { dir_i = 0; dir_j = 1; /* xy */ + if(GH->cctk_gsh[0]==1 || GH->cctk_gsh[1]==1) + continue; } else if (dir == 1) { dir_i = 0; dir_j = 2; /* xz */ + if(GH->cctk_gsh[0]==1 || GH->cctk_gsh[2]==1) + continue; } else { dir_i = 1; dir_j = 2; /* yz */ + if(GH->cctk_gsh[1]==1 || GH->cctk_gsh[2]==1) + continue; } /* set the origin using the slice center from IOUtil */ |