s4:objectclass LDB module - "ldb_msg_sanity_check" call not really needed
authorMatthias Dieter Wallnöfer <mdw@samba.org>
Mon, 4 Apr 2011 12:04:18 +0000 (14:04 +0200)
committerMatthias Dieter Wallnöfer <mdw@samba.org>
Thu, 7 Apr 2011 13:53:20 +0000 (15:53 +0200)
This call should only be performed at the beginning of a request.
"ldb_msg_sanity_check" checks for DN validity (which should already have been
done at the beginning of the request) and empty attributes (which should
be done by the "objectclass_attrs" LDB module).

Hence it is superflous here.

Reviewed-by: abartlet
source4/dsdb/samdb/ldb_modules/objectclass.c

index 4107c9cd7cc2f24becb062c36cd91c44dcd1b9ec..fd39937bc95d5d9a3b53784804ef26ba7497a557 100644 (file)
@@ -762,11 +762,6 @@ static int objectclass_do_add(struct oc_context *ac)
                }
        }
 
-       ret = ldb_msg_sanity_check(ldb, msg);
-       if (ret != LDB_SUCCESS) {
-               return ret;
-       }
-
        ret = ldb_build_add_req(&add_req, ldb, ac,
                                msg,
                                ac->req->controls,