From 9bca8b341f6fc6aeae66a2d3dde6a174c7f0cd6c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Love=20H=C3=B6rnquist=20=C3=85strand?= Date: Wed, 30 Apr 2008 08:23:05 +0000 Subject: [PATCH] Use _hx509_sel_yyerror() instead of error_message(). git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@23151 ec53bebd-3082-4978-b11e-865c3cabbd6b --- lib/hx509/sel-lex.l | 22 +--------------------- 1 file changed, 1 insertion(+), 21 deletions(-) diff --git a/lib/hx509/sel-lex.l b/lib/hx509/sel-lex.l index 8c26aabdd..53944897f 100644 --- a/lib/hx509/sel-lex.l +++ b/lib/hx509/sel-lex.l @@ -50,7 +50,6 @@ unsigned lineno = 1; static char * handle_string(void); static int lex_input(char *, int); -static void error_message (const char *format, ...); struct hx_expr_input _hx509_expr_input; @@ -81,25 +80,6 @@ TAILMATCH { return kw_TAILMATCH; } [ \t] ; %% -void -error_message (const char *format, ...) -{ - va_list args; - - if (_hx509_expr_input.error) - free(_hx509_expr_input.error); - - va_start (args, format); - vasprintf(&_hx509_expr_input.error, format, args); - va_end (args); -} - -void -_hx509_sel_yyerror (char *s) -{ - error_message("%s", s); -} - static char * handle_string(void) { @@ -115,7 +95,7 @@ handle_string(void) continue; } if(c == '\n'){ - error_message("unterminated string"); + _hx509_sel_yyerror("unterminated string"); lineno++; break; }