aboutsummaryrefslogtreecommitdiffstats
path: root/test.h
diff options
context:
space:
mode:
authorMattias Andrée <maandree@kth.se>2018-11-06 20:32:42 +0100
committerMattias Andrée <maandree@kth.se>2018-11-06 20:32:42 +0100
commit0335a7cf215f1c5cba9ae8a49b3dbd1b980a20b1 (patch)
treee87a3444037b27f7a2743ea84e7af1d9ef50c1bf /test.h
parentAdd tests for mem[p]setelem and add man pages for libsimple_default_failure_exit (diff)
downloadlibsimple-0335a7cf215f1c5cba9ae8a49b3dbd1b980a20b1.tar.gz
libsimple-0335a7cf215f1c5cba9ae8a49b3dbd1b980a20b1.tar.bz2
libsimple-0335a7cf215f1c5cba9ae8a49b3dbd1b980a20b1.tar.xz
Add libsimple_eprintf_preprint and libsimple_eprintf_postprint
Signed-off-by: Mattias Andrée <maandree@kth.se>
Diffstat (limited to 'test.h')
-rw-r--r--test.h12
1 files changed, 12 insertions, 0 deletions
diff --git a/test.h b/test.h
index 3aba488..29e6f13 100644
--- a/test.h
+++ b/test.h
@@ -83,3 +83,15 @@ size_t get_pagesize(void);
size_t round_up(size_t);
int have_custom_malloc(void); /* return 0 if run under valgrind(1) */
struct allocinfo *get_allocinfo(void *);
+
+
+int test_vfprintf(FILE *restrict stream, const char *restrict format, va_list ap);
+
+static inline int
+test_fprintf(FILE *restrict stream, const char *restrict format, ...)
+{
+ va_list ap;
+ va_start(ap, format);
+ return test_vfprintf(stream, format, ap);
+ va_end(ap);
+}