From: Michael Adam Date: Fri, 20 Nov 2009 11:44:43 +0000 (+0100) Subject: s3:idmap_ldap: trim the " chars from the location string in idmap_ldap_db_init X-Git-Tag: samba-4.0.0alpha9~305 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=7153200f21e1f30ba0ca7d629cc2c4e187ba605f;p=thirdparty%2Fsamba.git s3:idmap_ldap: trim the " chars from the location string in idmap_ldap_db_init When idmap backend is specified as idmap backend = ldap:"ldap://server1 ldap://server2" then currently "ldap://server1 ldap://server2" was passed to ldap_initialize including the quotes, leading to an ldap error. Michael --- diff --git a/source3/winbindd/idmap_ldap.c b/source3/winbindd/idmap_ldap.c index 99265594b96..cf322386142 100644 --- a/source3/winbindd/idmap_ldap.c +++ b/source3/winbindd/idmap_ldap.c @@ -856,6 +856,8 @@ static NTSTATUS idmap_ldap_db_init(struct idmap_domain *dom, } CHECK_ALLOC_DONE(ctx->url); + trim_char(ctx->url, '\"', '\"'); + tmp = lp_parm_const_string(-1, config_option, "ldap_base_dn", NULL); if ( ! tmp || ! *tmp) { tmp = lp_ldap_idmap_suffix();