diff options
author | Scott Ullrich <sullrich@pfsense.org> | 2007-03-21 16:28:08 +0000 |
---|---|---|
committer | Scott Ullrich <sullrich@pfsense.org> | 2007-03-21 16:28:08 +0000 |
commit | 5918fbaf3192409289f7f4cba030ff9c817ddc62 (patch) | |
tree | e00f639aed043f357f36a61c63254d26e1032361 /usr/local/captiveportal | |
parent | 01ccbfc1ccec282658ec896ba1342b6c7742e6e2 (diff) | |
download | pfsense-5918fbaf3192409289f7f4cba030ff9c817ddc62.zip pfsense-5918fbaf3192409289f7f4cba030ff9c817ddc62.tar.gz |
Silence eclipse errors
Diffstat (limited to 'usr/local/captiveportal')
-rw-r--r-- | usr/local/captiveportal/radius_accounting.inc | 15 | ||||
-rw-r--r-- | usr/local/captiveportal/radius_authentication.inc | 3 |
2 files changed, 6 insertions, 12 deletions
diff --git a/usr/local/captiveportal/radius_accounting.inc b/usr/local/captiveportal/radius_accounting.inc index 6bfc11b..50dfa20 100644 --- a/usr/local/captiveportal/radius_accounting.inc +++ b/usr/local/captiveportal/radius_accounting.inc @@ -86,8 +86,7 @@ function RADIUS_ACCOUNTING_START($ruleno,$username,$sessionid,$radiusip,$radiusp if (PEAR::isError($racct->start())) { $retvalue['acct_val'] = 1; $retvalue['error'] = $racct->getMessage(); - if ($debug) - printf("Radius start: %s<br>\n", $retvalue['error']); + // If we encounter an error immediately stop this function and go back $racct->close(); return $retvalue; @@ -126,16 +125,13 @@ function RADIUS_ACCOUNTING_START($ruleno,$username,$sessionid,$radiusip,$radiusp if (PEAR::isError($result)) { $retvalue['acct_val'] = 1; $retvalue['error'] = $result->getMessage(); - if ($debug) - printf("Radius send failed: %s<br>\n", $retvalue['error']); + } else if ($result === true) { $retvalue['acct_val'] = 5 ; - if ($debug) - printf("Radius Accounting succeeded<br>\n"); + } else { $retvalue['acct_val'] = 1 ; - if ($debug) - printf("Radius Accounting rejected<br>\n"); + } // close OO RADIUS_ACCOUNTING @@ -211,8 +207,7 @@ function RADIUS_ACCOUNTING_STOP($ruleno,$username,$sessionid,$start_time,$radius if (PEAR::isError($racct->start())) { $retvalue['acct_val'] = 1; $retvalue['error'] = $racct->getMessage(); - if ($debug) - printf("Radius start: %s<br>\n", $retvalue['error']); + // If we encounter an error immediately stop this function and go back $racct->close(); return $retvalue; diff --git a/usr/local/captiveportal/radius_authentication.inc b/usr/local/captiveportal/radius_authentication.inc index 1a4a7df..522dc22 100644 --- a/usr/local/captiveportal/radius_authentication.inc +++ b/usr/local/captiveportal/radius_authentication.inc @@ -89,8 +89,7 @@ function RADIUS_AUTHENTICATION($username,$password,$radiusservers,$clientip,$cli if (PEAR::isError($rauth->start())) { $retvalue['auth_val'] = 1; $retvalue['error'] = $rauth->getError(); - if ($debug) - printf("Radius start: %s<br>\n", $retvalue['error']); + // If we encounter an error immediately stop this function and go back $rauth->close(); return $retvalue; |