diff options
author | Volker Lendecke <vl@samba.org> | 2018-05-04 15:23:18 +0200 |
---|---|---|
committer | Jeremy Allison <jra@samba.org> | 2018-07-24 20:36:50 +0200 |
commit | da179b1e4c54bec67214546973ced7a16e4caec5 (patch) | |
tree | 6fbde109415cf78442b1ccc5a55da826a885b5e7 /nsswitch/wb_common.c | |
parent | d4c6b009223c1ed6caf538c35b42e16c98e2bded (diff) | |
download | samba-da179b1e4c54bec67214546973ced7a16e4caec5.tar.gz |
nsswitch: Correct users of "ctx->is_privileged"
winbindd_context->is_privileged is a bool
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
Diffstat (limited to 'nsswitch/wb_common.c')
-rw-r--r-- | nsswitch/wb_common.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/nsswitch/wb_common.c b/nsswitch/wb_common.c index df32789e177..42b341b8c1c 100644 --- a/nsswitch/wb_common.c +++ b/nsswitch/wb_common.c @@ -37,7 +37,7 @@ struct winbindd_context { static struct winbindd_context wb_global_ctx = { .winbindd_fd = -1, - .is_privileged = 0, + .is_privileged = false, .our_pid = 0 }; @@ -371,7 +371,7 @@ static int winbind_open_pipe_sock(struct winbindd_context *ctx, ctx->our_pid = getpid(); } - if ((need_priv != 0) && (ctx->is_privileged == 0)) { + if ((need_priv != 0) && !ctx->is_privileged) { winbind_close_sock(ctx); } @@ -389,7 +389,7 @@ static int winbind_open_pipe_sock(struct winbindd_context *ctx, return -1; } - ctx->is_privileged = 0; + ctx->is_privileged = false; /* version-check the socket */ @@ -422,13 +422,13 @@ static int winbind_open_pipe_sock(struct winbindd_context *ctx, if (fd != -1) { close(ctx->winbindd_fd); ctx->winbindd_fd = fd; - ctx->is_privileged = 1; + ctx->is_privileged = true; } SAFE_FREE(response.extra_data.data); } - if (ctx->is_privileged == 0) { + if (!ctx->is_privileged) { return -1; } |