mirror of
https://github.com/EGroupware/egroupware.git
synced 2025-06-26 04:41:41 +02:00
* LDAP: fix not working connect under newer PHP 5.6 (maybe other versions too) with PHP Warning: invalid port number: 0
This commit is contained in:
parent
9ca7b66290
commit
16c5e2deec
@ -188,7 +188,7 @@ class ldap
|
|||||||
$host = parse_url($host,PHP_URL_HOST);
|
$host = parse_url($host,PHP_URL_HOST);
|
||||||
}
|
}
|
||||||
// connect to ldap server (never fails, as connection happens in bind!)
|
// connect to ldap server (never fails, as connection happens in bind!)
|
||||||
if(!$this->ds = ldap_connect($host, $port))
|
if(!($this->ds = !empty($port) ? ldap_connect($host, $port) : ldap_connect($host)))
|
||||||
{
|
{
|
||||||
return False;
|
return False;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user