From 911aae05b5d3ffd2543333e27cf06778381c7b3c Mon Sep 17 00:00:00 2001 From: Tobias Klauser Date: Sat, 23 May 2009 15:14:45 +0200 Subject: New upstream release 15.7a, fixing CVE-2009-0148 --- src/scanner.l | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'src/scanner.l') diff --git a/src/scanner.l b/src/scanner.l index ef32a41..8c5160d 100644 --- a/src/scanner.l +++ b/src/scanner.l @@ -44,7 +44,7 @@ #define IFLEVELINC 5 /* #if nesting level size increment */ -static char const rcsid[] = "$Id: scanner.l,v 1.7 2004/01/08 14:07:20 broeker Exp $"; +static char const rcsid[] = "$Id: scanner.l,v 1.8 2007/03/09 23:54:34 broeker Exp $"; int first; /* buffer index for first char of symbol */ int last; /* buffer index for last char of symbol */ @@ -95,8 +95,8 @@ int comment(void); #else /* Assume this is the AT&T/SCO style lex */ #undef input -#define input() ((yytchar=(yytchar=yysptr>yysbuf?*(unsigned char *)--yysptr:getc(yyin))=='/'?comment():yytchar)==EOF?0:yytchar) -#define noncommentinput() ((yytchar=yysptr>yysbuf?*--yysptr:getc(yyin))==EOF?0:yytchar) +#define input() ((yytchar=(yytchar=yysptr>yysbuf?*(unsigned char *)--yysptr:getc(yyin))=='/'?comment():yytchar)==EOF?LEXEOF:yytchar) +#define noncommentinput() ((yytchar=yysptr>yysbuf?*--yysptr:getc(yyin))==EOF?LEXEOF:yytchar) #undef unput #define unput(c) (*yysptr++=(c)) @@ -685,7 +685,7 @@ comment_input(void) c = getc (yyin); - return c; + return (c == EOF) ? LEXEOF : c; } int -- cgit v1.2.3-54-g00ecf