diff options
author | Simo Sorce <idra@samba.org> | 2006-05-21 23:58:09 +0000 |
---|---|---|
committer | Gerald (Jerry) Carter <jerry@samba.org> | 2007-10-10 14:08:20 -0500 |
commit | d51f4fb2c7c4f2eaee8f67769e76f05c5a289996 (patch) | |
tree | 7a78add9595d391aa4217d7508008c5a76efc578 /source4 | |
parent | efa3803335e85fab6cbd93c33353c7e3db624afa (diff) | |
download | samba-d51f4fb2c7c4f2eaee8f67769e76f05c5a289996.tar.gz samba-d51f4fb2c7c4f2eaee8f67769e76f05c5a289996.tar.bz2 samba-d51f4fb2c7c4f2eaee8f67769e76f05c5a289996.zip |
r15789: hmm, damn, testing uncovcer all your bugs :-)
(This used to be commit 977982c884da15d1e9f5fe19d24cd4169ecbb0c5)
Diffstat (limited to 'source4')
-rw-r--r-- | source4/dsdb/samdb/ldb_modules/samldb.c | 18 |
1 files changed, 2 insertions, 16 deletions
diff --git a/source4/dsdb/samdb/ldb_modules/samldb.c b/source4/dsdb/samdb/ldb_modules/samldb.c index 706c0bb5c3..e662b2a663 100644 --- a/source4/dsdb/samdb/ldb_modules/samldb.c +++ b/source4/dsdb/samdb/ldb_modules/samldb.c @@ -625,20 +625,6 @@ static int samldb_fill_user_or_computer_object(struct ldb_module *module, const return LDB_ERR_OPERATIONS_ERROR; } - /* make sure we also add person, organizationalPerson and top */ - if ( ! samldb_find_or_add_attribute(module, msg2, "objectclass", "person", "person")) { - talloc_free(mem_ctx); - return LDB_ERR_OPERATIONS_ERROR; - } - if ( ! samldb_find_or_add_attribute(module, msg2, "objectclass", "organizationalPerson", "organizationalPerson")) { - talloc_free(mem_ctx); - return LDB_ERR_OPERATIONS_ERROR; - } - if ( ! samldb_find_or_add_attribute(module, msg2, "objectclass", "top", "top")) { - talloc_free(mem_ctx); - return LDB_ERR_OPERATIONS_ERROR; - } - /* meddle with objectclass */ if (ldb_msg_find_element(msg2, "samAccountName") == NULL) { @@ -841,8 +827,8 @@ static int samldb_add_async(struct ldb_module *module, struct ldb_request *req) } /* is user or computer? */ - if ((samldb_find_attribute(msg, "objectclass", "user") == NULL) && - (samldb_find_attribute(msg, "objectclass", "computer") == NULL)) { + if ((samldb_find_attribute(msg, "objectclass", "user") != NULL) || + (samldb_find_attribute(msg, "objectclass", "computer") != NULL)) { /* add all relevant missing objects */ ret = samldb_fill_user_or_computer_object(module, msg, &msg2); if (ret) { |