From 7ac3261f9707ef5071410636906a55a434c6cff3 Mon Sep 17 00:00:00 2001 From: Elizabeth Myers Date: Wed, 23 Mar 2016 09:25:56 -0500 Subject: [PATCH] Ensure the parser/lexer don't use IRCD_BUFSIZE. --- ircd/ircd_lexer.l | 6 +++--- ircd/ircd_parser.y | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/ircd/ircd_lexer.l b/ircd/ircd_lexer.l index b7982587..e993c88a 100644 --- a/ircd/ircd_lexer.l +++ b/ircd/ircd_lexer.l @@ -53,8 +53,8 @@ void cinclude(void); void hashcomment(void); int ieof(void); int lineno_stack[MAX_INCLUDE_DEPTH]; -char conffile_stack[MAX_INCLUDE_DEPTH][IRCD_BUFSIZE]; -char conffilebuf[IRCD_BUFSIZE+1]; +char conffile_stack[MAX_INCLUDE_DEPTH][BUFSIZE]; +char conffilebuf[BUFSIZE+1]; char *current_file = conffilebuf; FILE *inc_fbfile_in[MAX_INCLUDE_DEPTH]; @@ -195,7 +195,7 @@ void cinclude(void) if (tmp_fbfile_in == NULL) { /* if its not found in PREFIX, look in ETCPATH */ - char fnamebuf[IRCD_BUFSIZE]; + char fnamebuf[BUFSIZE]; snprintf(fnamebuf, sizeof(fnamebuf), "%s/%s", ETCPATH, c); tmp_fbfile_in = fopen(fnamebuf, "r"); diff --git a/ircd/ircd_parser.y b/ircd/ircd_parser.y index eb49d7f8..bc5e3fcc 100644 --- a/ircd/ircd_parser.y +++ b/ircd/ircd_parser.y @@ -161,7 +161,7 @@ static void add_cur_list(int type, char *str, int number) %union { int number; - char string[IRCD_BUFSIZE + 1]; + char string[BUFSIZE + 1]; conf_parm_t * conf_parm; }