]> git.sur5r.net Git - openldap/commitdiff
SLAPI plugins are no longer global; global SLAPI plugins should be
authorLuke Howard <lukeh@openldap.org>
Fri, 22 Jul 2005 03:17:36 +0000 (03:17 +0000)
committerLuke Howard <lukeh@openldap.org>
Fri, 22 Jul 2005 03:17:36 +0000 (03:17 +0000)
associated with the frontend

servers/slapd/slapi/plugin.c

index 7063c00f78be01270f65fdc3bfceadf2195ca479..e9793cb72e939fe139fbc8f1bac03653da80b11e 100644 (file)
@@ -163,7 +163,7 @@ slapi_int_register_plugin(
        Slapi_PBlock *pSavePB;
        int    rc = LDAP_SUCCESS;
 
-       assert( be != NULL ); /* global plugins are now stored in frontendDB */
+       assert( be != NULL );
 
        pTmpPB = (Slapi_PBlock *)be->be_pb;
        if ( pTmpPB == NULL ) {
@@ -217,32 +217,7 @@ slapi_int_get_plugins(
                goto done;
        }
 
-       /*
-        * First, count the plugins associated with a specific
-        * backend.
-        */
-       if ( be != frontendDB ) {
-               pCurrentPB = (Slapi_PBlock *)be->be_pb;
-
-               while ( pCurrentPB != NULL && rc == LDAP_SUCCESS ) {
-                       rc = slapi_pblock_get( pCurrentPB, functype, &FuncPtr );
-                       if ( rc == LDAP_SUCCESS ) {
-                               if ( FuncPtr != NULL )  {
-                                       numPB++;
-                               }
-                               rc = slapi_pblock_get( pCurrentPB,
-                                       SLAPI_IBM_PBLOCK, &pCurrentPB );
-                       }
-               }
-       }
-       if ( rc != LDAP_SUCCESS ) {
-               goto done;
-       }
-
-       /*
-        * Then, count the global plugins.
-        */
-       pCurrentPB = (Slapi_PBlock *)frontendDB->be_pb;
+       pCurrentPB = (Slapi_PBlock *)be->be_pb;
 
        while ( pCurrentPB != NULL && rc == LDAP_SUCCESS ) {
                rc = slapi_pblock_get( pCurrentPB, functype, &FuncPtr );
@@ -254,9 +229,6 @@ slapi_int_get_plugins(
                                SLAPI_IBM_PBLOCK, &pCurrentPB );
                }
        }
-       if ( rc != LDAP_SUCCESS ) {
-               goto done;
-       }
 
        if ( numPB == 0 ) {
                *ppFuncPtrs = NULL;
@@ -275,23 +247,7 @@ slapi_int_get_plugins(
                goto done;
        }
 
-       if ( be != frontendDB ) {
-               pCurrentPB = (Slapi_PBlock *)be->be_pb;
-
-               while ( pCurrentPB != NULL && rc == LDAP_SUCCESS )  {
-                       rc = slapi_pblock_get( pCurrentPB, functype, &FuncPtr );
-                       if ( rc == LDAP_SUCCESS ) {
-                               if ( FuncPtr != NULL )  {
-                                       *pTmpFuncPtr = FuncPtr;
-                                       pTmpFuncPtr++;
-                               } 
-                               rc = slapi_pblock_get( pCurrentPB,
-                                               SLAPI_IBM_PBLOCK, &pCurrentPB );
-                       }
-               }
-       }
-
-       pCurrentPB = (Slapi_PBlock *)frontendDB->be_pb;
+       pCurrentPB = (Slapi_PBlock *)be->be_pb;
 
        while ( pCurrentPB != NULL && rc == LDAP_SUCCESS )  {
                rc = slapi_pblock_get( pCurrentPB, functype, &FuncPtr );
@@ -304,7 +260,7 @@ slapi_int_get_plugins(
                                        SLAPI_IBM_PBLOCK, &pCurrentPB );
                }
        }
-       *pTmpFuncPtr = NULL ;
+
 
 done:
        if ( rc != LDAP_SUCCESS && *ppFuncPtrs != NULL ) {