From: Andrew Tridgell Date: Fri, 22 Aug 2008 08:37:34 +0000 (+1000) Subject: fixed the GUID and objectSID canonicalisation functions X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=115053ea7e70b067e7873668ed83f1f10908287d;p=thirdparty%2Fsamba.git fixed the GUID and objectSID canonicalisation functions --- diff --git a/source/lib/ldb-samba/ldif_handlers.c b/source/lib/ldb-samba/ldif_handlers.c index 04fcd66b6eb..a16582d2945 100644 --- a/source/lib/ldb-samba/ldif_handlers.c +++ b/source/lib/ldb-samba/ldif_handlers.c @@ -134,6 +134,7 @@ static int ldb_canonicalise_objectSid(struct ldb_context *ldb, void *mem_ctx, /* Perhaps not a string after all */ return ldb_handler_copy(ldb, mem_ctx, in, out); } + return 0; } return ldb_handler_copy(ldb, mem_ctx, in, out); } @@ -148,7 +149,7 @@ static int ldif_read_objectGUID(struct ldb_context *ldb, void *mem_ctx, char *guid_string; NTSTATUS status; enum ndr_err_code ndr_err; - guid_string = talloc_strndup(mem_ctx, in->data, in->length); + guid_string = talloc_strndup(mem_ctx, (const char *)in->data, in->length); if (!guid_string) { return -1; } @@ -251,6 +252,7 @@ static int ldb_canonicalise_objectGUID(struct ldb_context *ldb, void *mem_ctx, /* Perhaps it wasn't a valid string after all */ return ldb_handler_copy(ldb, mem_ctx, in, out); } + return 0; } return ldb_handler_copy(ldb, mem_ctx, in, out); }