From 26ca6cc5a91375b46089448806e65f54031da0ae Mon Sep 17 00:00:00 2001 From: yye00 Date: Thu, 12 Aug 2004 22:17:36 +0000 Subject: assert fix git-svn-id: http://svn.cactuscode.org/arrangements/CactusBase/SymBase/trunk@15 906471b6-c639-44d1-9ea0-3e3d6879f074 --- doc/documentation.tex | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/doc/documentation.tex b/doc/documentation.tex index 8e1808b..b0fcbf8 100644 --- a/doc/documentation.tex +++ b/doc/documentation.tex @@ -252,7 +252,7 @@ The code to find out which boundaries should have a physical boundary condition applied might look as follows: \begin{verbatim} -#include +#include "cctk.h" #include "util_Table.h" CCTK_INT symtable; @@ -261,10 +261,12 @@ int face; int ierr; symtable = SymmetryTableHandleForGrid (cctkGH); -assert (symtable>=0); +if (symtable<0) + CCTK_VWarn(0, __LINE__, __FILE__, "Thorn_Name", "symtable is out of bounds"); ierr = Util_TableGetIntArray (symtable, 6, symbnd, "symmetry_handle"); -assert (ierr==6); +if (ierr!=6) + CCTK_VWarn(0, __LINE__, __FILE__, "Thorn_Name", "Util_TableGetIntArray returned error"); for (face=0; face<6; ++face) { if (cctk_bbox[face] && symbnd[face]<0) { -- cgit v1.2.3