shithub: scc

ref: 51f244d2ec7cce0cd116df73b29e3c9ff5cc3425
dir: /src/libscc/die.c/

View raw version
static char sccsid[] = "@(#) ./lib/scc/die.c";
#include <stdarg.h>
#include <stdlib.h>
#include <stdio.h>

#include <scc/scc.h>

int failure;

void
die(const char *fmt, ...)
{
	failure = 1;
	va_list va;
	va_start(va, fmt);
	vfprintf(stderr, fmt, va);
	putc('\n', stderr);
	va_end(va);
	exit(1);
}