summaryrefslogtreecommitdiff
path: root/accel-pppd/ctrl/pptp
diff options
context:
space:
mode:
authorGuillaume Nault <g.nault@alphalink.fr>2016-05-09 21:41:00 +0200
committerDmitry Kozlov <xeb@mail.ru>2016-05-11 13:26:02 +0300
commitf21ca06be19609f12584ddc96620d21b9a7b32a5 (patch)
tree5d9eaa5b6b97f80fbc3e09fc0740e5edba83a616 /accel-pppd/ctrl/pptp
parent448d99b34e18c94cabe9c41e12fd678212acf103 (diff)
downloadaccel-ppp-f21ca06be19609f12584ddc96620d21b9a7b32a5.tar.gz
accel-ppp-f21ca06be19609f12584ddc96620d21b9a7b32a5.zip
iprange: don't warn about empty iprange config if no modules depend on it
Move warning messages to PPTP and L2TP modules. No other module actually uses iprange, so it's perfectly valid to disable it, or at least to not configure any range, when PPTP and L2TP aren't used. Signed-off-by: Guillaume Nault <g.nault@alphalink.fr>
Diffstat (limited to 'accel-pppd/ctrl/pptp')
-rw-r--r--accel-pppd/ctrl/pptp/pptp.c13
1 files changed, 13 insertions, 0 deletions
diff --git a/accel-pppd/ctrl/pptp/pptp.c b/accel-pppd/ctrl/pptp/pptp.c
index 0a0afa4d..ec20586f 100644
--- a/accel-pppd/ctrl/pptp/pptp.c
+++ b/accel-pppd/ctrl/pptp/pptp.c
@@ -773,6 +773,19 @@ static void load_config(void)
}
conf_ip_pool = conf_get_opt("pptp", "ip-pool");
+
+ switch (iprange_check_activation()) {
+ case IPRANGE_DISABLED:
+ log_warn("pptp: iprange module disabled, improper IP configuration of PPP interfaces may cause kernel soft lockup\n");
+ break;
+ case IPRANGE_NO_RANGE:
+ log_warn("pptp: no IP address range defined in section [%s], incoming PPTP connections will be rejected\n",
+ IPRANGE_CONF_SECTION);
+ break;
+ default:
+ /* Makes compiler happy */
+ break;
+ }
}
static void pptp_init(void)