X-Git-Url: http://mj.ucw.cz/gitweb/?a=blobdiff_plain;f=judge%2Ftoken.c;h=85f5069420e96755f2f98e7299f3fa4469055f12;hb=8899c2c556642997331657cbf69176f56c93ee44;hp=4606395483935493c2d8715099174c389254b820;hpb=def7011b3ec2f20cc195a4405198e03eb6c92b47;p=moe.git diff --git a/judge/token.c b/judge/token.c index 4606395..85f5069 100644 --- a/judge/token.c +++ b/judge/token.c @@ -34,9 +34,9 @@ void tok_err(struct tokenizer *t, char *msg, ...) { va_list args; va_start(args, msg); - printf("%s:%d: ", t->stream->name, t->line); - vprintf(msg, args); - putchar('\n'); + fprintf(stderr, "Error at %s line %d:\n", t->stream->name, t->line); + vfprintf(stderr, msg, args); + fputc('\n', stderr); va_end(args); exit(1); }