diff options
Diffstat (limited to 'cil/test/small1/testharness.h')
-rw-r--r-- | cil/test/small1/testharness.h | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/cil/test/small1/testharness.h b/cil/test/small1/testharness.h new file mode 100644 index 00000000..a1057e34 --- /dev/null +++ b/cil/test/small1/testharness.h @@ -0,0 +1,17 @@ +#ifndef printf + /* sm: this works with gcc-2.95 */ + extern int printf(const char * format, ...); +# ifdef CCURED + #pragma ccuredvararg("printf", printf(1)) +# endif +#else + /* but in gcc-3 headers it's a macro.. */ + #include <stdio.h> /* printf */ +#endif + +extern void exit(int); + +/* Always call E with a non-zero number */ +#define E(n) { printf("Error %d\n", n); exit(n); } +#define SUCCESS { printf("Success\n"); exit(0); } + |