diff options
-rw-r--r-- | lib/libsqlite3/tool/lemon.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/libsqlite3/tool/lemon.c b/lib/libsqlite3/tool/lemon.c index 0b41bdc44b7..034cccf3d0a 100644 --- a/lib/libsqlite3/tool/lemon.c +++ b/lib/libsqlite3/tool/lemon.c @@ -4021,11 +4021,12 @@ void ReportHeader(struct lemon *lemp) else prefix = ""; in = file_open(lemp,".h","rb"); if( in ){ + int eof; for(i=1; i<lemp->nterminal && fgets(line,LINESIZE,in); i++){ sprintf(pattern,"#define %s%-30s %2d\n",prefix,lemp->symbols[i]->name,i); if( strcmp(line,pattern) ) break; } - int eof = fgetc(in); + eof = fgetc(in); fclose(in); if( i==lemp->nterminal && eof == EOF ){ /* No change in the file. Don't rewrite it. */ |