]> git.sur5r.net Git - openldap/blobdiff - servers/slapd/back-bdb/group.c
Add calls to module_init/module_kill to support dynamically loaded backends.
[openldap] / servers / slapd / back-bdb / group.c
index 1d75d60202aa7caeb2742e18c1474f0dbceaea59..20b768bbdb8c366af44cc8b773bcb89c4d071b1b 100644 (file)
@@ -40,7 +40,6 @@ bdb_group(
        int     rc = 1;
        Attribute *attr;
 
-       AttributeDescription *ad_objectClass = slap_schema.si_ad_objectClass;
        const char *group_oc_name = NULL;
        const char *group_at_name = group_at->ad_cname.bv_val;
 
@@ -82,8 +81,13 @@ bdb_group(
        if ( txn ) {
                locker = TXN_ID( txn );
        } else {
-               /* XXYYZ: need to check return value */
-               LOCK_ID ( bdb->bi_dbenv, &locker );
+               rc = LOCK_ID ( bdb->bi_dbenv, &locker );
+               switch(rc) {
+               case 0:
+                       break;
+               default:
+                       return 1;
+               }
        }
 
        if (dn_match(&target->e_name, gr_ndn)) {