From c5c38d622754c5b06716cbae41a27af711d22bcf Mon Sep 17 00:00:00 2001 From: Michael Adam Date: Mon, 21 Jan 2008 15:31:57 +0100 Subject: Fix formatting of multi_sz registry values. Don't print only the last component. Michael (This used to be commit 654e96208ec847e32797cbd2442ef9e73c014567) --- source3/libnet/libnet_conf.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'source3') diff --git a/source3/libnet/libnet_conf.c b/source3/libnet/libnet_conf.c index ec05fa7c16..fc797bbeb9 100644 --- a/source3/libnet/libnet_conf.c +++ b/source3/libnet/libnet_conf.c @@ -320,8 +320,12 @@ static char *libnet_conf_format_registry_value(TALLOC_CTX *mem_ctx, case REG_MULTI_SZ: { uint32 j; for (j = 0; j < value->v.multi_sz.num_strings; j++) { - result = talloc_asprintf(mem_ctx, "\"%s\" ", + result = talloc_asprintf(mem_ctx, "%s \"%s\" ", + result, value->v.multi_sz.strings[j]); + if (result == NULL) { + break; + } } break; } -- cgit