diff -r f345bda72bc4 -r 43e37759235e Symbian3/Examples/guid-6013a680-57f9-415b-8851-c4fa63356636/fail_8c_source.html --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/Symbian3/Examples/guid-6013a680-57f9-415b-8851-c4fa63356636/fail_8c_source.html Tue Mar 30 16:16:55 2010 +0100 @@ -0,0 +1,42 @@ + + +
+ +00001 /* +00002 * fail.c +00003 * Copyright (C) 1998 A.J. van Os +00004 * +00005 * Description: +00006 * An alternative form of assert() +00007 */ +00008 +00009 #include <stdlib.h> +00010 #include "antiword.h" +00011 +00012 #if !defined(NDEBUG) +00013 void +00014 __fail(char *szExpression, char *szFilename, int iLineNumber) +00015 { +00016 if (szExpression == NULL || szFilename == NULL) { +00017 werr(1, "Internal error: no expression"); +00018 } +00019 #if defined(DEBUG) +00020 fprintf(stderr, "%s[%3d]: Internal error in '%s'\n", +00021 szFilename, iLineNumber, szExpression); +00022 #endif /* DEBUG */ +00023 werr(1, "Internal error in '%s' in file %s at line %d", +00024 szExpression, szFilename, iLineNumber); +00025 } /* end of __fail */ +00026 #endif /* !NDEBUG */ +