From: Alan T. DeKok Date: Tue, 12 Sep 2017 15:09:09 +0000 (-0400) Subject: ignore internal servers, and print out more helpful messages X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=5ea766dd19bd974e487187bde97a28884cfda1ac;p=thirdparty%2Ffreeradius-server.git ignore internal servers, and print out more helpful messages --- diff --git a/src/main/virtual_servers.c b/src/main/virtual_servers.c index e52aada9f6d..578cc987844 100644 --- a/src/main/virtual_servers.c +++ b/src/main/virtual_servers.c @@ -489,11 +489,17 @@ int virtual_servers_bootstrap(CONF_SECTION *config) return -1; } + /* + * Ignore internally generated "server" sections, + * they're for the unit tests. + */ + if (!cf_filename(cs)) continue; + /* * Forbid old-style virtual servers. */ if (!cf_pair_find(cs, "namespace")) { - cf_log_err(cs, "server sections must set 'namesspace = ...'"); + cf_log_err(cs, "server %s { ...} section must set 'namesspace = ...'", server_name); return -1; } }