summaryrefslogtreecommitdiffstats
path: root/etc/inc/interfaces.inc
diff options
context:
space:
mode:
authorgnhb <gnoahb@gmail.com>2010-05-04 15:35:29 +0700
committergnhb <gnoahb@gmail.com>2010-05-04 15:35:29 +0700
commit42809b4a0394bf4f06e7a74bd5f7612e2513d0a4 (patch)
tree4c9974bb9577266888eed951d5f09626542878de /etc/inc/interfaces.inc
parentde77ffdb1e62343a9483c7ab2cdf594ad6dc482d (diff)
downloadpfsense-42809b4a0394bf4f06e7a74bd5f7612e2513d0a4.zip
pfsense-42809b4a0394bf4f06e7a74bd5f7612e2513d0a4.tar.gz
Use "PPPs" as the new Tab name in Interfaces -> Assign. Rename files and update affected files.
Also, add upgrade_config function 062_to_063.
Diffstat (limited to 'etc/inc/interfaces.inc')
-rw-r--r--etc/inc/interfaces.inc18
1 files changed, 10 insertions, 8 deletions
diff --git a/etc/inc/interfaces.inc b/etc/inc/interfaces.inc
index 94c5311..d11c52f 100644
--- a/etc/inc/interfaces.inc
+++ b/etc/inc/interfaces.inc
@@ -884,13 +884,14 @@ function interface_ppp_configure($interface) {
$wancfg = &$config['interfaces'][$interface];
if (is_array($config['ppps']['ppp']) && count($config['ppps']['ppp'])) {
foreach ($config['ppps']['ppp'] as $pppid => $ppp) {
- //$ppp['port'] = $ppp['ports'];
- if ($interface == $ppp['ifname'])
+ if ($wancfg['ptpid'] == $ppp['ptpid'])
break;
}
}
- if (!$ppp || !isset($ppp['ifname']))
- return;
+ if (!$ppp || $wancfg['ptpid'] != $ppp['ptpid'] || stristr($ppp['ports'], ",")){
+ log_error("PPP configuration error.");
+ return;
+ }
/*
if ($interface == "wan")
$pppid = "0";
@@ -996,7 +997,7 @@ EOD;
EOD;
$mpdconf .= <<<EOD
- set modem device {$ppp['port']}
+ set modem device {$ppp['ports']}
set modem script DialPeer
set modem idle-script Ringback
set modem watch -cd
@@ -1039,11 +1040,11 @@ EOD;
fclose($fd);
// Launch specified ppp instance
- if (file_exists("{$ppp['port']}")) {
+ if (file_exists("{$ppp['ports']}")) {
/* fire up mpd */
mwexec("/usr/local/sbin/mpd5 -b -k -d {$g['varetc_path']} -f mpd_{$interface}.conf -p {$g['varrun_path']}/ppp_{$interface}.pid -s {$interface} pppclient");
} else
- log_error("Device {$ppp['port']} has disappeared.");
+ log_error("Device {$ppp['ports']} has disappeared.");
}
function interfaces_carp_setup() {
@@ -2640,7 +2641,7 @@ function get_real_interface($interface = "wan") {
$counter++;
}
break;
- case "pppoe":
+/* case "pppoe":
if ($if == "wan")
$wanif = "pppoe0";
else
@@ -2658,6 +2659,7 @@ function get_real_interface($interface = "wan") {
else
$wanif = "ppp" . substr($if, 3);
break;
+*/
default:
$wanif = $cfg['if'];
break;
OpenPOWER on IntegriCloud