arm: protect state after signal handler
[minix.git] / commands / service / util.c
blob71b4f75708d24611e26f03cd21bd6ec1de4e8d85
2 #include <stdarg.h>
3 #include <stdio.h>
4 #include <stdlib.h>
6 void fatal(char *fmt, ...)
8 va_list ap;
10 fprintf(stderr, "service: fatal error: ");
11 va_start(ap, fmt);
12 vfprintf(stderr, fmt, ap);
13 va_end(ap);
14 fprintf(stderr, "\n");
16 exit(1);
19 void warning(char *fmt, ...)
21 va_list ap;
23 fprintf(stderr, "service: warning: ");
24 va_start(ap, fmt);
25 vfprintf(stderr, fmt, ap);
26 va_end(ap);
27 fprintf(stderr, "\n");