summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--source3/lib/substitute.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/source3/lib/substitute.c b/source3/lib/substitute.c
index 752f1085837..bc34c317974 100644
--- a/source3/lib/substitute.c
+++ b/source3/lib/substitute.c
@@ -524,9 +524,10 @@ char *talloc_sub_basic(TALLOC_CTX *mem_ctx,
group_name = gidtoname(pass->pw_gid);
if (is_domain_name) {
- p = strchr_m(group_name, *sep);
- if (p != NULL) {
- group_name = p + 1;
+ char *group_sep;
+ group_sep = strchr_m(group_name, *sep);
+ if (group_sep != NULL) {
+ group_name = group_sep + 1;
}
}
a_string = realloc_string_sub(a_string,