]> git.ipfire.org Git - thirdparty/openldap.git/commitdiff
Import -USLAPD_ALIAS_DEREF removal of alias deref'ing codes
authorKurt Zeilenga <kurt@openldap.org>
Wed, 20 Jan 1999 02:17:22 +0000 (02:17 +0000)
committerKurt Zeilenga <kurt@openldap.org>
Wed, 20 Jan 1999 02:17:22 +0000 (02:17 +0000)
servers/slapd/back-ldbm/alias.c
servers/slapd/back-ldbm/proto-back-ldbm.h
servers/slapd/back-ldbm/search.c

index 75cd074db2c0ec112a4126c66b58441d6a97b941..621f8c352793f0a2d692e302a3e7ca9a6d29f590 100644 (file)
@@ -12,6 +12,8 @@
 
 #include "portable.h"
 
+#ifndef SLAPD_ALIAS_DEREF
+
 #include <stdio.h>
 #include <string.h>
 #include <ac/socket.h>         /* Get struct sockaddr for slap.h */
@@ -243,3 +245,5 @@ char *derefDN ( Backend     *be,
 
   return newDN;
 }
+
+#endif SLAPD_ALIAS_DEREF
index b51691eb4cc1443adea2f221a41c3e12bf835c95..c70d20a1c013d616b823641aefb5a6c41a30c1a7 100644 (file)
@@ -8,6 +8,7 @@ LDAP_BEGIN_DECL
 /*
  * alias.c
  */
+#ifdef SLAPD_ALIAS_DEREF
 Entry *derefAlias_r LDAP_P((
        Backend     *be,
        Connection      *conn,
@@ -18,6 +19,7 @@ char *derefDN LDAP_P((
        Connection  *conn,
        Operation   *op,
        char        *dn ));
+#endif
 
 /*
  * attr.c
index 15c0d3f6a701648340fa5b92973ba66e69e8ff59..abf63a967aec90a35a025780766e075de03067e3 100644 (file)
@@ -76,6 +76,7 @@ ldbm_back_search(
         * the subordinates of the base
         */
 
+#ifdef SLAPD_DEREF
        switch ( deref ) {
        case LDAP_DEREF_FINDING:
        case LDAP_DEREF_ALWAYS:
@@ -84,6 +85,9 @@ ldbm_back_search(
        default:
                realBase = ch_strdup(base);
        }
+#else
+               realBase = ch_strdup(base);
+#endif
 
        (void) dn_normalize (realBase);
 
@@ -244,6 +248,7 @@ ldbm_back_search(
                                                return( 0 );
                                        }
 
+#ifdef SLAPD_DEREF
                                        /*
                                         * check and apply aliasing where the dereferencing applies to
                                         * the subordinates of the base
@@ -258,6 +263,7 @@ ldbm_back_search(
                                                }
                                                break;
                                        }
+#endif
 
                                        switch ( send_search_entry( be, conn, op, e,
                                                attrs, attrsonly ) ) {