From: Peter Verthez Date: Tue, 22 Jan 2002 20:16:16 +0000 (+0000) Subject: Get rid of compiler warning from lex generated code. X-Git-Url: https://git.dlugolecki.net.pl/?a=commitdiff_plain;h=4e81582268d1fe7a45df84fa8b136279f59cb63e;p=gedcom-parse.git Get rid of compiler warning from lex generated code. --- diff --git a/gedcom/gedcom_lex_common.c b/gedcom/gedcom_lex_common.c index 9e53de5..6f7a1d3 100644 --- a/gedcom/gedcom_lex_common.c +++ b/gedcom/gedcom_lex_common.c @@ -284,11 +284,15 @@ int test_loop(ENCODING enc, char* code) return CLOSE; \ } \ else { \ + char* ptr; int size; \ /* Reset our state */ \ current_level = -1; \ level_diff = MAXGEDCLEVEL; \ /* ... then terminate lex */ \ yyterminate(); \ + /* Get rid of f*cking compiler warning from lex generated code */ \ + /* yyterminate does return(), so program will never come here */ \ + yy_flex_realloc(ptr, size); \ } \ }