mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-11-08 09:05:16 +01: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);
|
||||
}
|
||||
// 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;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user