From dfb6062f9dd0bef7821da808035dbd6f67557802 Mon Sep 17 00:00:00 2001 From: Bill Currie Date: Mon, 11 Jun 2001 17:51:09 +0000 Subject: [PATCH] fix an out-by-one for line directives at the beginning of the file --- tools/qfcc/source/pr_lex.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/tools/qfcc/source/pr_lex.c b/tools/qfcc/source/pr_lex.c index caff6c449..0bc4f49ee 100644 --- a/tools/qfcc/source/pr_lex.c +++ b/tools/qfcc/source/pr_lex.c @@ -131,9 +131,11 @@ PR_NewLine (void) pr_file_p++; if (!*pr_file_p) PR_ParseError ("Unexpected end of file"); - m = false; - pr_source_line = line - 1; + pr_source_line = line - (m != false); s_file = ReuseString (pr_immediate_string); + if (!m) + pr_file_p++; + m = false; } pr_source_line++;