From cdaec3be3a1f7c0193de2c97bc6fdbebc3451423 Mon Sep 17 00:00:00 2001 From: Volker Lendecke Date: Sat, 18 Mar 2017 18:53:58 +0100 Subject: [PATCH] idmap: Use idmap_config_bool in idmap_init_domain Signed-off-by: Volker Lendecke Reviewed-by: Michael Adam --- source3/winbindd/idmap.c | 12 +----------- 1 file changed, 1 insertion(+), 11 deletions(-) diff --git a/source3/winbindd/idmap.c b/source3/winbindd/idmap.c index be4ee643654..602d3cd1fc7 100644 --- a/source3/winbindd/idmap.c +++ b/source3/winbindd/idmap.c @@ -361,7 +361,6 @@ static struct idmap_domain *idmap_init_domain(TALLOC_CTX *mem_ctx, { struct idmap_domain *result; NTSTATUS status; - char *config_option = NULL; const char *range; unsigned low_id = 0; unsigned high_id = 0; @@ -405,18 +404,9 @@ static struct idmap_domain *idmap_init_domain(TALLOC_CTX *mem_ctx, * load ranges and read only information from the config */ - config_option = talloc_asprintf(result, "idmap config %s", - result->name); - if (config_option == NULL) { - DEBUG(0, ("Out of memory!\n")); - goto fail; - } - - result->read_only = lp_parm_bool(-1, config_option, "read only", false); + result->read_only = idmap_config_bool(result->name, "read only", false); range = idmap_config_const_string(result->name, "range", NULL); - talloc_free(config_option); - if (range == NULL) { if (check_range) { DEBUG(1, ("idmap range not specified for domain %s\n", -- 2.47.3