]> git.sur5r.net Git - openldap/blobdiff - servers/slapd/overlays/collect.c
Plug memleak when query isn't added to cache
[openldap] / servers / slapd / overlays / collect.c
index 9cd0a344260197cf13b21d30abed3ea6885a6198..08e1bee42b00eec8fc83a38f0da2df16756c0eee 100644 (file)
@@ -2,7 +2,7 @@
 /* $OpenLDAP$ */
 /* This work is part of OpenLDAP Software <http://www.openldap.org/>.
  *
- * Copyright 2003-2004 The OpenLDAP Foundation.
+ * Copyright 2003-2006 The OpenLDAP Foundation.
  * Portions Copyright 2003 Howard Chu.
  * All rights reserved.
  *
@@ -72,7 +72,7 @@ collect_response( Operation *op, SlapReply *rs )
                        /* Extract the values of the desired attribute from
                         * the ancestor entry
                         */
-                       rc = backend_attribute( op, NULL, &ci->ci_dn, ci->ci_ad, &vals );
+                       rc = backend_attribute( op, NULL, &ci->ci_dn, ci->ci_ad, &vals, ACL_READ );
 
                        /* If there are any values, merge them into the
                         * current entry
@@ -153,7 +153,7 @@ static int collect_config(
 
 static slap_overinst collect;
 
-int collect_init() {
+int collect_initialize() {
        collect.on_bi.bi_type = "collect";
        collect.on_bi.bi_db_config = collect_config;
        collect.on_response = collect_response;
@@ -163,7 +163,7 @@ int collect_init() {
 
 #if SLAPD_OVER_COLLECT == SLAPD_MOD_DYNAMIC
 int init_module(int argc, char *argv[]) {
-       return collect_init();
+       return collect_initialize();
 }
 #endif