From: cajus Date: Tue, 6 Jun 2006 11:59:43 +0000 (+0000) Subject: Added robustness fix X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=7ec371d58ed4da5f3c0a88c8d20e0276c3396506;p=gosa.git Added robustness fix git-svn-id: https://oss.gonicus.de/repositories/gosa/branches/2.5@3657 594d385d-05f5-0310-b6e9-bd551577e9d8 --- diff --git a/include/class_ldap.inc b/include/class_ldap.inc index b6a11be99..7b82a8b32 100644 --- a/include/class_ldap.inc +++ b/include/class_ldap.inc @@ -65,9 +65,10 @@ class LDAP{ function convert($dn) { if (SPECIALS_OVERRIDE == TRUE){ - return (preg_replace(array("/\\\\,/", "/\\\\2C/", "/\(/", "/\)/", "/\//"), + $tmp= preg_replace(array("/\\\\,/", "/\\\\2C/", "/\(/", "/\)/", "/\//"), array("\001CO", "\001CO", "\001OB", "\001CB", "\001SL"), - $dn)); + $dn); + return (preg_replace('/,\s+/', ',', $tmp)); } else { return ($dn); }