From df7e6b4c031b865c56fcf44644f1bf9c700885d8 Mon Sep 17 00:00:00 2001 From: Stefan Kost Date: Fri, 4 Dec 2009 18:33:22 +0200 Subject: [PATCH] scanner: don't warn about unexpected characters when the char is \0 --- giscanner/scannerlexer.l | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/giscanner/scannerlexer.l b/giscanner/scannerlexer.l index 3d9aa333..d78de905 100644 --- a/giscanner/scannerlexer.l +++ b/giscanner/scannerlexer.l @@ -190,7 +190,7 @@ stringtext ([^\\\"])|(\\.) "\""{stringtext}*"\"" { return STRING; } "L\""{stringtext}*"\"" { return STRING; } -. { fprintf(stderr, "%s:%d: unexpected character `%c'\n", scanner->current_filename, lineno, yytext[0]); } +. { if (yytext[0]) fprintf(stderr, "%s:%d: unexpected character `%c'\n", scanner->current_filename, lineno, yytext[0]); } %% -- 2.34.1