From 002cacab57caab1923be6b4b75b96ac3aae7a65f Mon Sep 17 00:00:00 2001 From: jim-p Date: Wed, 16 Nov 2011 16:38:27 -0500 Subject: Fix this ifconfig-push to also account for tap. --- etc/inc/openvpn.inc | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'etc/inc/openvpn.inc') diff --git a/etc/inc/openvpn.inc b/etc/inc/openvpn.inc index d478c53..9729217 100644 --- a/etc/inc/openvpn.inc +++ b/etc/inc/openvpn.inc @@ -737,7 +737,10 @@ function openvpn_resync_csc(& $settings) { $serverip = long2ip32($baselong + 1); $clientip = long2ip32($baselong + 2); /* Because this is being pushed, the order from the client's point of view. */ - $conf .= "ifconfig-push {$clientip} {$serverip}\n"; + if ($settings['dev_mode'] == 'tun') + $conf .= "ifconfig-push {$clientip} {$serverip}\n"; + else + $conf .= "ifconfig-push {$clientip} {$mask}\n"; } openvpn_add_dhcpopts($settings, $conf); -- cgit v1.1