From b841d12a138a4b9a73f159a7056b0efd64de1289 Mon Sep 17 00:00:00 2001 From: Matthias Dieter Wallnöfer Date: Wed, 3 Nov 2010 16:21:37 +0100 Subject: s4:objectclass_attrs LDB module - simplify the invoke of the "dSHeuristics" checker It's always invoked on add and modify operations. --- source4/dsdb/samdb/ldb_modules/objectclass_attrs.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'source4/dsdb/samdb') diff --git a/source4/dsdb/samdb/ldb_modules/objectclass_attrs.c b/source4/dsdb/samdb/ldb_modules/objectclass_attrs.c index 120357cf9e..f609e9210b 100644 --- a/source4/dsdb/samdb/ldb_modules/objectclass_attrs.c +++ b/source4/dsdb/samdb/ldb_modules/objectclass_attrs.c @@ -200,14 +200,15 @@ static int attr_handler(struct oc_context *ac) talloc_free(res); } } -/* dSHeuristics syntax check */ - if ((ac->req->operation == LDB_ADD || ac->req->operation == LDB_MODIFY) && - (ldb_attr_cmp(attr->lDAPDisplayName, "dSHeuristics") == 0)) { + + /* "dSHeuristics" syntax check */ + if (ldb_attr_cmp(attr->lDAPDisplayName, "dSHeuristics") == 0) { ret = oc_validate_dsheuristics(&(msg->elements[i])); if (ret != LDB_SUCCESS) { return ret; } } + /* Substitute the attribute name to match in case */ msg->elements[i].name = attr->lDAPDisplayName; } -- cgit