summaryrefslogtreecommitdiff
path: root/source4/libnet/libnet_lookup.c
diff options
context:
space:
mode:
Diffstat (limited to 'source4/libnet/libnet_lookup.c')
-rw-r--r--source4/libnet/libnet_lookup.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/source4/libnet/libnet_lookup.c b/source4/libnet/libnet_lookup.c
index e8bceb9218..d194c1a73c 100644
--- a/source4/libnet/libnet_lookup.c
+++ b/source4/libnet/libnet_lookup.c
@@ -419,7 +419,9 @@ NTSTATUS libnet_LookupName_recv(struct composite_context *c, TALLOC_CTX *mem_ctx
struct lsa_TransSidArray *sids = s->lookup.out.sids;
if (domains == NULL || sids == NULL) {
- composite_error(c, NT_STATUS_UNSUCCESSFUL);
+ status = NT_STATUS_UNSUCCESSFUL;
+ io->out.error_string = talloc_asprintf(mem_ctx, "Error: %s", nt_errstr(status));
+ goto done;
}
if (sids->count > 0) {
@@ -440,6 +442,7 @@ NTSTATUS libnet_LookupName_recv(struct composite_context *c, TALLOC_CTX *mem_ctx
io->out.error_string = talloc_asprintf(mem_ctx, "Error: %s", nt_errstr(status));
}
+done:
talloc_free(c);
return status;
}