From 875610cfcce8fd9e0617949e844a783e38a1ba6d Mon Sep 17 00:00:00 2001 From: Kurt Zeilenga Date: Tue, 30 May 2000 18:32:10 +0000 Subject: [PATCH] Referral hack --- libraries/libldap/request.c | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/libraries/libldap/request.c b/libraries/libldap/request.c index 2d93469e97..488317d7fd 100644 --- a/libraries/libldap/request.c +++ b/libraries/libldap/request.c @@ -653,15 +653,12 @@ ldap_chase_referrals( LDAP *ld, LDAPRequest *lr, char **errstrp, int *hadrefp ) continue; } - /* NOTE! This code treats "ldap://host/" differently - * from "ldap://host". The behavior is wrong, but is - * left here intentionally to maintain compatibility - * with OpenLDAP 1.x and UMich 3.3 clients. - */ *hadrefp = 1; + if (( refdn = strchr( tmpref, '/' )) != NULL ) { *refdn++ = '\0'; - newdn = 1; + newdn = refdn[0] != '?' && refdn[0] != '\0'; + } else { newdn = 0; } -- 2.39.5