summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--source3/winbindd/idmap_tdb_common.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/source3/winbindd/idmap_tdb_common.c b/source3/winbindd/idmap_tdb_common.c
index 2b16d0ba31..b232729763 100644
--- a/source3/winbindd/idmap_tdb_common.c
+++ b/source3/winbindd/idmap_tdb_common.c
@@ -320,9 +320,11 @@ NTSTATUS idmap_tdb_common_unixids_to_sids(struct idmap_domain * dom,
talloc_get_type_abort(dom->private_data,
struct idmap_tdb_common_context);
- unixid_to_sid_fn =
- (ctx->unixid_to_sid_fn ==
- NULL) ? idmap_tdb_common_unixid_to_sid : ctx->unixid_to_sid_fn;
+ if (ctx->unixid_to_sid_fn == NULL) {
+ unixid_to_sid_fn = idmap_tdb_common_unixid_to_sid;
+ } else {
+ unixid_to_sid_fn = ctx->unixid_to_sid_fn;
+ }
/* initialize the status to avoid surprise */
for (i = 0; ids[i]; i++) {