--- backup-stock-image-20100320/inc/pfsense-utils.inc 2010-03-23 13:42:51.000000000 +0700 +++ pfsense-utils.inc.new 2010-03-22 18:44:16.000000000 +0700 @@ -1299,15 +1298,17 @@ $ifinfo['pptplink'] = "down"; break; /* PPP interface? -> get uptime for this session and cumulative uptime from the persistant log file in conf */ - case "": + case "ppp": if ($config['interfaces'][$if]['serialport']){ $dev = $config['interfaces'][$if]['serialport']; if (file_exists("/dev/{$dev}")){ $ifinfo['ppplink'] = $dev; if (file_exists("/var/run/{$dev}.sock") && file_exists("/var/run/{$dev}.if")){ - $ifinfo['ppp_uptime'] = `/usr/sbin/pppctl /var/run/$dev.sock show physical | grep 'Connect time' | cut -c 15-`; - } //else if (`/sbin/ifconfig + $ifinfo['ppp_uptime'] = trim(`/usr/sbin/pppctl /var/run/$dev.sock bg echo UPTIME`); + if (stristr($ifinfo['ppp_uptime'],">")) + $ifinfo['ppp_uptime'] = substr($ifinfo['ppp_uptime'], 2 + strpos($ifinfo['ppp_uptime'], ">")); + } $ifinfo['missing_device'] = 0; } else{