From 8fd6ce613a4c1b35e1c1435bdd99af96de1d6bdf Mon Sep 17 00:00:00 2001 From: Andrew Tridgell Date: Sat, 19 Sep 2009 18:41:22 -0700 Subject: s4-ldb: display an error if we can't decode a NDR blob --- source4/lib/ldb-samba/ldif_handlers.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'source4/lib/ldb-samba/ldif_handlers.c') diff --git a/source4/lib/ldb-samba/ldif_handlers.c b/source4/lib/ldb-samba/ldif_handlers.c index 5a60a37da2..d1bdd957ee 100644 --- a/source4/lib/ldb-samba/ldif_handlers.c +++ b/source4/lib/ldb-samba/ldif_handlers.c @@ -54,7 +54,9 @@ static int ldif_write_NDR(struct ldb_context *ldb, void *mem_ctx, p, pull_fn); if (err != NDR_ERR_SUCCESS) { talloc_free(p); - return ldb_handler_copy(ldb, mem_ctx, in, out); + out->data = (uint8_t *)talloc_strdup(mem_ctx, ""); + out->length = strlen((const char *)out->data); + return 0; } out->data = (uint8_t *)ndr_print_struct_string(mem_ctx, print_fn, "NDR", p); talloc_free(p); -- cgit