]> git.ipfire.org Git - thirdparty/freeradius-server.git/commitdiff
If we can't load DHCP, complain. Closes #869
authorAlan T. DeKok <aland@freeradius.org>
Tue, 6 Jan 2015 19:07:05 +0000 (14:07 -0500)
committerAlan T. DeKok <aland@freeradius.org>
Tue, 6 Jan 2015 19:07:05 +0000 (14:07 -0500)
src/main/listen.c

index 21680dba5c28bb57c1c7828c3156036819f6c235..dcd6638468305809bb09bd8441071173ef9a87b4 100644 (file)
@@ -2812,7 +2812,7 @@ static rad_listen_t *listen_parse(CONF_SECTION *cs, char const *server)
                talloc_set_destructor(marker, _free_proto_handle);
 
                if (master_listen[type].magic !=  RLM_MODULE_INIT) {
-                       ERROR("Failed to load protocol '%s' due to internal sanity check problem",
+                       ERROR("Failed to load protocol '%s', it has the wrong version.",
                               master_listen[type].name);
                        return NULL;
                }
@@ -2837,6 +2837,15 @@ static rad_listen_t *listen_parse(CONF_SECTION *cs, char const *server)
                return NULL;
        }
 
+       /*
+        *      DHCP and VMPS *must* be loaded dynamically.
+        */
+       if (master_listen[type].magic !=  RLM_MODULE_INIT) {
+               ERROR("Cannot load protocol '%s', as the required library does not exist",
+                     master_listen[type].name);
+               return NULL;
+       }
+
        /*
         *      Allow listen sections in the default config to
         *      refer to a server.
@@ -2882,7 +2891,6 @@ static rad_listen_t *listen_parse(CONF_SECTION *cs, char const *server)
                return NULL;
        }
 
-
        server_cs = cf_section_sub_find_name2(main_config.config, "server",
                                              this->server);
        if (!server_cs && this->server) {