aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorjim-p <jimp@pfsense.org>2011-03-17 09:17:49 -0400
committerjim-p <jimp@pfsense.org>2011-03-17 09:18:56 -0400
commit3df3f3327d9f0579479315be06e6ad75eccb246e (patch)
tree163a9b06070f91d1383f6e3da0ba7a325d498259
parent61676806852bc46250c6777718815929f356a682 (diff)
downloadpfsense-packages-3df3f3327d9f0579479315be06e6ad75eccb246e.tar.gz
pfsense-packages-3df3f3327d9f0579479315be06e6ad75eccb246e.tar.bz2
pfsense-packages-3df3f3327d9f0579479315be06e6ad75eccb246e.zip
Use is_numeric here instead of just testing the variable (it will fail if the usrid is 0, when that should be valid)
-rwxr-xr-xconfig/openvpn-client-export/openvpn-client-export.inc2
1 files changed, 1 insertions, 1 deletions
diff --git a/config/openvpn-client-export/openvpn-client-export.inc b/config/openvpn-client-export/openvpn-client-export.inc
index c58a6c53..82eae161 100755
--- a/config/openvpn-client-export/openvpn-client-export.inc
+++ b/config/openvpn-client-export/openvpn-client-export.inc
@@ -118,7 +118,7 @@ function openvpn_client_export_config($srvid, $usrid, $crtid, $useaddr, $usetoke
}
// lookup user info
- if ($usrid) {
+ if (is_numeric($usrid)) {
$user = $config['system']['user'][$usrid];
if (!$user) {
$input_errors[] = "Could not find user settings.";