From: Steve Murphy Date: Mon, 13 Nov 2006 19:15:12 +0000 (+0000) Subject: This solves bug 8342, whereby a crash occurs under certain circumstances while readin... X-Git-Tag: 1.4.0-beta4~129 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=2a0ac6ad9a471e0e0b728aa113971484728cefa9;p=thirdparty%2Fasterisk.git This solves bug 8342, whereby a crash occurs under certain circumstances while reading a config file with comments-- a call to CB_ADD shouldn't happen if withcomments is zero git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@47576 65c4cc65-6c06-0410-ace0-fbb531ad65f3 --- diff --git a/main/config.c b/main/config.c index ccbc0c3309..cf520a1c05 100644 --- a/main/config.c +++ b/main/config.c @@ -905,7 +905,7 @@ static struct ast_config *config_text_file_load(const char *database, const char new_buf = comment_p + 1; } } - if( comment && !process_buf ) + if( withcomments && comment && !process_buf ) { CB_ADD(buf); /* the whole line is a comment, store it */ }