aboutsummaryrefslogblamecommitdiff
path: root/8.1/error.c
blob: 85cd7f0134a3f5acdd69b07e489b93ab151b6703 (plain) (tree)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
















                                    
#include <stdio.h>
#include <stdarg.h>
#include <stdlib.h>
#include "error.h"

void error(char *fmt, ...)
{
	va_list args;
	va_start(args, fmt);

	fprintf(stderr, "error: ");
	vfprintf(stderr, fmt, args);
	fprintf(stderr, "\n");

	va_end(args);
	exit(1);
}