From 1b20002cc246f6bab6fe2369412bd4c65311785f Mon Sep 17 00:00:00 2001 From: Andrew Tridgell Date: Thu, 10 Dec 2009 14:31:13 +1100 Subject: libcli: use GUID_to_ndr_blob() --- libcli/ldap/ldap_ndr.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) (limited to 'libcli') diff --git a/libcli/ldap/ldap_ndr.c b/libcli/ldap/ldap_ndr.c index dd820ff8d5..6f1bb4ee37 100644 --- a/libcli/ldap/ldap_ndr.c +++ b/libcli/ldap/ldap_ndr.c @@ -64,11 +64,10 @@ char *ldap_encode_ndr_dom_sid(TALLOC_CTX *mem_ctx, const struct dom_sid *sid) char *ldap_encode_ndr_GUID(TALLOC_CTX *mem_ctx, struct GUID *guid) { DATA_BLOB blob; - enum ndr_err_code ndr_err; + NTSTATUS status; char *ret; - ndr_err = ndr_push_struct_blob(&blob, mem_ctx, NULL, guid, - (ndr_push_flags_fn_t)ndr_push_GUID); - if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) { + status = GUID_to_ndr_blob(guid, mem_ctx, &blob); + if (!NT_STATUS_IS_OK(status)) { return NULL; } ret = ldb_binary_encode(mem_ctx, blob); -- cgit