diff options
author | Fernando J V da Silva <fernandojvsilva@yahoo.com.br> | 2009-11-25 17:01:55 -0300 |
---|---|---|
committer | Andrew Tridgell <tridge@samba.org> | 2009-11-30 21:17:27 +1100 |
commit | 71e29cbf56048791057ccf07b859654312f3882e (patch) | |
tree | 7f413aa6586987f9d1a4817fd85bf66feee2e3d7 /source4/dsdb/samdb/ldb_modules/repl_meta_data.c | |
parent | 0003b5fad1dee687bc15dfad9f71b6dfc40556d7 (diff) | |
download | samba-71e29cbf56048791057ccf07b859654312f3882e.tar.gz samba-71e29cbf56048791057ccf07b859654312f3882e.tar.bz2 samba-71e29cbf56048791057ccf07b859654312f3882e.zip |
s4-drs: Using dsdb_msg_add_guid() utility function
Uses the dsdb_msg_add_guid() to add any kind of GUID attribute
to a ldb_message in several places of samba4 code.
Signed-off-by: Andrew Tridgell <tridge@samba.org>
Diffstat (limited to 'source4/dsdb/samdb/ldb_modules/repl_meta_data.c')
-rw-r--r-- | source4/dsdb/samdb/ldb_modules/repl_meta_data.c | 12 |
1 files changed, 1 insertions, 11 deletions
diff --git a/source4/dsdb/samdb/ldb_modules/repl_meta_data.c b/source4/dsdb/samdb/ldb_modules/repl_meta_data.c index 37aa399ef1..bfde2df1d1 100644 --- a/source4/dsdb/samdb/ldb_modules/repl_meta_data.c +++ b/source4/dsdb/samdb/ldb_modules/repl_meta_data.c @@ -411,7 +411,6 @@ static int replmd_add(struct ldb_module *module, struct ldb_request *req) struct ldb_message *msg; const DATA_BLOB *guid_blob; struct GUID guid; - struct ldb_val guid_value; struct replPropertyMetaDataBlob nmd; struct ldb_val nmd_value; const struct GUID *our_invocation_id; @@ -580,15 +579,6 @@ static int replmd_add(struct ldb_module *module, struct ldb_request *req) } /* generated NDR encoded values */ - ndr_err = ndr_push_struct_blob(&guid_value, msg, - NULL, - &guid, - (ndr_push_flags_fn_t)ndr_push_GUID); - if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) { - ldb_oom(ldb); - talloc_free(ac); - return LDB_ERR_OPERATIONS_ERROR; - } ndr_err = ndr_push_struct_blob(&nmd_value, msg, lp_iconv_convenience(ldb_get_opaque(ldb, "loadparm")), &nmd, @@ -602,7 +592,7 @@ static int replmd_add(struct ldb_module *module, struct ldb_request *req) /* * add the autogenerated values */ - ret = ldb_msg_add_value(msg, "objectGUID", &guid_value, NULL); + ret = dsdb_msg_add_guid(msg, &guid, "objectGUID"); if (ret != LDB_SUCCESS) { ldb_oom(ldb); talloc_free(ac); |