diff options
author | goodale <goodale@b589c3ab-70e8-4b4d-a09f-cba2dd200880> | 1999-11-03 09:29:35 +0000 |
---|---|---|
committer | goodale <goodale@b589c3ab-70e8-4b4d-a09f-cba2dd200880> | 1999-11-03 09:29:35 +0000 |
commit | da453eedc9ebd8af963fc4b1219b7e00c73d8510 (patch) | |
tree | 20dfdf32717be5426de7e249f810a9ae8d0ecc2a /src/WriteInfo.c | |
parent | 5b469bd4a94f2cba17ca871a39548eb671dd1da6 (diff) |
Fixing various things pointed out by compiling with -Wall.
Tom
git-svn-id: http://svn.cactuscode.org/arrangements/CactusBase/IOBasic/trunk@16 b589c3ab-70e8-4b4d-a09f-cba2dd200880
Diffstat (limited to 'src/WriteInfo.c')
-rw-r--r-- | src/WriteInfo.c | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/src/WriteInfo.c b/src/WriteInfo.c index ae3d035..e3a17a7 100644 --- a/src/WriteInfo.c +++ b/src/WriteInfo.c @@ -16,22 +16,27 @@ #include <stdio.h> #include "cctk.h" -#include "cctk_parameters.h" #include "CactusBase/IOUtil/src/ioGH.h" CCTK_REAL IOBasic_WriteInfo (cGH *GH, int index, const char *operator, const char *alias) { - DECLARE_CCTK_PARAMETERS CCTK_REAL tt[1]; int reduce_handle; CCTK_REAL retval; reduce_handle = CCTK_ReductionHandle(operator); + if (reduce_handle > -1) { CCTK_Reduce(GH,-1,reduce_handle,1,CCTK_VARIABLE_REAL,tt,1,index); retval = tt[0]; } + else + { + CCTK_WARN(1, "Reduction operator doesn't exist."); + + retval = -27; + } return retval; |