aboutsummaryrefslogtreecommitdiff
path: root/Carpet/CarpetSlab
diff options
context:
space:
mode:
authorThomas Radke <tradke@aei.mpg.de>2005-04-10 14:07:00 +0000
committerThomas Radke <tradke@aei.mpg.de>2005-04-10 14:07:00 +0000
commit2316fa8db64063bbb89b1553281cc896fe0f2584 (patch)
tree22cdf1c92b8024a66f7ef4da0d997b942d82dcdb /Carpet/CarpetSlab
parent36111464c327d7d80364578c6ffdc35705502afb (diff)
CarpetSlab: fix return value for CarpetSlab_GetList()
The return code of CarpetSlab_Get() must be checked against 0 for successful completion. The return code of CarpetSlab_GetList() should be the number of slabs returned, or negative in case of errors. darcs-hash:20050410140710-776a0-f293cb8176f10a3cc4fd20a2a0eae71fbda09d9e.gz
Diffstat (limited to 'Carpet/CarpetSlab')
-rw-r--r--Carpet/CarpetSlab/src/Get.cc4
1 files changed, 2 insertions, 2 deletions
diff --git a/Carpet/CarpetSlab/src/Get.cc b/Carpet/CarpetSlab/src/Get.cc
index a6d303122..dbfa48b08 100644
--- a/Carpet/CarpetSlab/src/Get.cc
+++ b/Carpet/CarpetSlab/src/Get.cc
@@ -94,10 +94,10 @@ namespace CarpetSlab {
retvals[n] = CarpetSlab_Get (cctkGH, mapping_handle, procs[n],
vindices[n], timelevels[n], hdatatypes[n],
hdata[n]);
- everyting_okay = everyting_okay && retvals[n];
+ everyting_okay = everyting_okay && retvals[n] == 0;
}
- return everyting_okay ? 0 : -1;
+ return everyting_okay ? num_arrays : -1;
}