s4:SAMLDB module - ignore referrals
authorMatthias Dieter Wallnöfer <mwallnoefer@yahoo.de>
Tue, 23 Feb 2010 16:59:55 +0000 (17:59 +0100)
committerAndrew Bartlett <abartlet@samba.org>
Wed, 24 Feb 2010 21:16:46 +0000 (08:16 +1100)
They don't cause any harm to our functionality - so ignore them were not needed.

Signed-off-by: Andrew Bartlett <abartlet@samba.org>
source4/dsdb/samdb/ldb_modules/samldb.c

index 6420e05ba89fd81dd4c0456a936d3eeab45c5971..24d1450d9cce2351398938649d045ee4573e0619 100644 (file)
@@ -210,9 +210,10 @@ static int samldb_check_samAccountName_callback(struct ldb_request *req,
                                        LDB_ERR_ENTRY_ALREADY_EXISTS);
 
        case LDB_REPLY_REFERRAL:
-               /* this should not happen */
-               return ldb_module_done(ac->req, NULL, NULL,
-                                       LDB_ERR_OPERATIONS_ERROR);
+               /* ignore */
+               talloc_free(ares);
+               ret = LDB_SUCCESS;
+               break;
 
        case LDB_REPLY_DONE:
                /* not found, go on */
@@ -610,9 +611,9 @@ static int samldb_find_for_defaultObjectCategory_callback(struct ldb_request *re
                break;
 
        case LDB_REPLY_REFERRAL:
-               /* this should not happen */
+               /* ignore */
                talloc_free(ares);
-               ret = LDB_ERR_OPERATIONS_ERROR;
+               ret = LDB_SUCCESS;
                break;
 
        case LDB_REPLY_DONE: