Don't accept "[SSL]" in config when no SSL support is built in

This commit is contained in:
Alexander Barton 2012-02-26 15:52:12 +01:00
parent 5cbdcf4f0d
commit c38751191f
1 changed files with 7 additions and 4 deletions

View File

@ -854,10 +854,13 @@ Read_Config( bool ngircd_starting )
/* Is this the beginning of a new section? */
if(( str[0] == '[' ) && ( str[strlen( str ) - 1] == ']' )) {
strlcpy( section, str, sizeof( section ));
if (strcasecmp(section, "[GLOBAL]") == 0 ||
strcasecmp(section, "[LIMITS]") == 0 ||
strcasecmp(section, "[OPTIONS]") == 0 ||
strcasecmp(section, "[SSL]") == 0)
if (strcasecmp(section, "[GLOBAL]") == 0
|| strcasecmp(section, "[LIMITS]") == 0
|| strcasecmp(section, "[OPTIONS]") == 0
#ifdef SSL_SUPPORT
|| strcasecmp(section, "[SSL]") == 0
#endif
)
continue;
if( strcasecmp( section, "[SERVER]" ) == 0 ) {