Imported from antiword-0.33.tar.gz.
[antiword.git] / unix.c
blob7df3ea1279b9cef12317f3af09750c4f046c2f61
1 /*
2 * unix.c
3 * Copyright (C) 1998-2000 A.J. van Os; Released under GPL
5 * Description:
6 * Unix approximations of RISC-OS functions
7 */
9 #include <stdio.h>
10 #include <stdlib.h>
11 #include <stdarg.h>
12 #include "antiword.h"
16 * werr - write an error message and exit if needed
18 void
19 werr(int iFatal, const char *szFormat, ...)
21 va_list tArg;
23 va_start(tArg, szFormat);
24 (void)vfprintf(stderr, szFormat, tArg);
25 va_end(tArg);
26 fprintf(stderr, "\n");
27 switch (iFatal) {
28 case 0: /* The message is just a warning, so no exit */
29 return;
30 case 1: /* Fatal error with a standard exit */
31 exit(EXIT_FAILURE);
32 default: /* Fatal error with a non-standard exit */
33 exit(iFatal);
35 } /* end of werr */
37 void
38 visdelay_begin(void)
40 } /* end of visdelay_begin */
42 void
43 visdelay_end(void)
45 } /* end of visdelay_end */