summaryrefslogtreecommitdiff
path: root/source3/winbindd/idmap_tdb_common.c
diff options
context:
space:
mode:
authorMichael Adam <obnox@samba.org>2012-09-19 02:57:37 +0200
committerStefan Metzmacher <metze@samba.org>2012-09-20 05:20:38 +0200
commitd1de2b4d3999dda96df9156da30a239af3b2b88e (patch)
treea66d42ff8d4ef9708f2e8ce1d2cd969f88ec13f7 /source3/winbindd/idmap_tdb_common.c
parent03055af9b2af8a5a1c23946369a21d6437cf1b8c (diff)
downloadsamba-d1de2b4d3999dda96df9156da30a239af3b2b88e.tar.gz
samba-d1de2b4d3999dda96df9156da30a239af3b2b88e.tar.bz2
samba-d1de2b4d3999dda96df9156da30a239af3b2b88e.zip
s3:winbind:idmap_tdb_common: improve readability of assignment by adding an "if"
in idmap_tdb_common_unixids_to_sids()
Diffstat (limited to 'source3/winbindd/idmap_tdb_common.c')
-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++) {