From 18e3573c81a581b298f46eb7428153c24eb3a93c Mon Sep 17 00:00:00 2001 From: Pierangelo Masarati Date: Mon, 20 Oct 2008 21:15:13 +0000 Subject: [PATCH] declare support for read controls (ITS#5757) --- servers/slapd/back-null/null.c | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) diff --git a/servers/slapd/back-null/null.c b/servers/slapd/back-null/null.c index bc80698716..b95eeadb81 100644 --- a/servers/slapd/back-null/null.c +++ b/servers/slapd/back-null/null.c @@ -184,6 +184,34 @@ null_back_db_destroy( Backend *be, ConfigReply *cr ) int null_back_initialize( BackendInfo *bi ) { + static char *controls[] = { + LDAP_CONTROL_ASSERT, + LDAP_CONTROL_MANAGEDSAIT, + LDAP_CONTROL_PAGEDRESULTS, + LDAP_CONTROL_SUBENTRIES, +#if 0 /* do not declare support for write operation specific controls */ + LDAP_CONTROL_NOOP, + LDAP_CONTROL_PRE_READ, + LDAP_CONTROL_POST_READ, + LDAP_CONTROL_X_PERMISSIVE_MODIFY, +#ifdef LDAP_X_TXN + LDAP_CONTROL_X_TXN_SPEC, +#endif +#endif + NULL + }; + + Debug( LDAP_DEBUG_TRACE, + "null_back_initialize: initialize null backend\n", 0, 0, 0 ); + + bi->bi_flags |= + SLAP_BFLAG_INCREMENT | + SLAP_BFLAG_SUBENTRIES | + SLAP_BFLAG_ALIASES | + SLAP_BFLAG_REFERRALS; + + bi->bi_controls = controls; + bi->bi_open = 0; bi->bi_close = 0; bi->bi_config = 0; -- 2.39.5