diff options
Diffstat (limited to 'src/etc/inc/openvpn.inc')
-rw-r--r-- | src/etc/inc/openvpn.inc | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/etc/inc/openvpn.inc b/src/etc/inc/openvpn.inc index d74aa3e..c163294 100644 --- a/src/etc/inc/openvpn.inc +++ b/src/etc/inc/openvpn.inc @@ -694,7 +694,7 @@ function openvpn_reconfigure($mode, $settings) { $cert = lookup_cert($settings['certref']); /* XXX: Seems not used at all! */ $servercn = urlencode(cert_get_cn($cert['crt'])); - $conf .= "tls-verify \"/usr/local/sbin/ovpn_auth_verify tls '{$servercn}' {$settings['cert_depth']} \"\n"; + $conf .= "tls-verify \"/usr/local/sbin/ovpn_auth_verify tls '{$servercn}' {$settings['cert_depth']}\"\n"; } } @@ -1229,8 +1229,8 @@ function openvpn_get_active_servers($type="multipoint") { } function openvpn_get_server_status($server, $socket) { - $errval; - $errstr; + $errval = null; + $errstr = null; $fp = @stream_socket_client($socket, $errval, $errstr, 1); if ($fp) { stream_set_timeout($fp, 1); @@ -1323,7 +1323,7 @@ function openvpn_get_active_clients() { $client['vpnid'] = $settings['vpnid']; $client['mgmt'] = "client{$client['vpnid']}"; $socket = "unix://{$g['varetc_path']}/openvpn/{$client['mgmt']}.sock"; - $client['status'] = "down"; + $client['status']="down"; $clients[] = openvpn_get_client_status($client, $socket); } @@ -1332,8 +1332,8 @@ function openvpn_get_active_clients() { } function openvpn_get_client_status($client, $socket) { - $errval; - $errstr; + $errval = null; + $errstr = null; $fp = @stream_socket_client($socket, $errval, $errstr, 1); if ($fp) { stream_set_timeout($fp, 1); |