From b8ed2efb50b4a689e02b86d4c626d96ee7b2717f Mon Sep 17 00:00:00 2001 From: Andreas Schneider Date: Thu, 6 Dec 2012 15:14:07 +0100 Subject: nsswitch: Cleanup code in parse_wbinfo_domain_user(). MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Found by Coverity. Signed-off-by: Andreas Schneider Reviewed-by: Günther Deschner --- nsswitch/wbinfo.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'nsswitch') diff --git a/nsswitch/wbinfo.c b/nsswitch/wbinfo.c index 0e102dc858..b96b73c2bf 100644 --- a/nsswitch/wbinfo.c +++ b/nsswitch/wbinfo.c @@ -121,7 +121,8 @@ static bool parse_wbinfo_domain_user(const char *domuser, fstring domain, if (!p) { /* Maybe it was a UPN? */ - if ((p = strchr(domuser, '@')) != NULL) { + p = strchr(domuser, '@'); + if (p != NULL) { fstrcpy(domain, ""); fstrcpy(user, domuser); return true; -- cgit