From 21b024aa82b49a05919e89885e60913c8cb444b2 Mon Sep 17 00:00:00 2001 From: Stefan Metzmacher Date: Thu, 13 Dec 2007 09:13:35 +0100 Subject: r26423: try to fix the build on solaris metze (This used to be commit 5b62180946a7cb9f3981ce740cfe830f6f0a00ff) --- source4/param/loadparm.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'source4') diff --git a/source4/param/loadparm.c b/source4/param/loadparm.c index 07b8cbbdf4..8b84cefc19 100644 --- a/source4/param/loadparm.c +++ b/source4/param/loadparm.c @@ -2252,7 +2252,12 @@ struct loadparm_context *loadparm_init(TALLOC_CTX *mem_ctx) parm_table[i].type == P_USTRING) && parm_table[i].offset != -1 && !(lp_ctx->flags[i] & FLAG_CMDLINE)) { - char **r = ((char *)(parm_table[i].class == P_LOCAL)?&sDefault:lp_ctx->globals) + parm_table[i].offset; + char **r; + if (parm_table[i].class == P_LOCAL) { + r = (char **)(&sDefault + parm_table[i].offset); + } else { + r = (char **)(lp_ctx->globals + parm_table[i].offset); + } *r = talloc_strdup(lp_ctx, ""); } } -- cgit