Genesis-Plus-GX/source/unused/dos/error.c
ekeeke31 217ca8de3f
2007-08-10 20:34:06 +00:00

30 lines
386 B
C

#include "osd.h"
FILE *error_log;
struct {
int enabled;
int verbose;
FILE *log;
} t_error;
void error_init(void)
{
error_log = fopen("error.log","w");
}
void error_shutdown(void)
{
if(error_log) fclose(error_log);
}
void error(char *format, ...)
{
va_list ap;
va_start(ap, format);
if(error_log) vfprintf(error_log, format, ap);
va_end(ap);
}