From patchwork Wed Feb 15 16:15:19 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jeff Layton X-Patchwork-Id: 9574395 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 72BB960493 for ; Wed, 15 Feb 2017 16:15:39 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 62DAE2846B for ; Wed, 15 Feb 2017 16:15:39 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 57B06284CD; Wed, 15 Feb 2017 16:15:39 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.8 required=2.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_HI,T_DKIM_INVALID autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 062B72846B for ; Wed, 15 Feb 2017 16:15:39 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752141AbdBOQPi (ORCPT ); Wed, 15 Feb 2017 11:15:38 -0500 Received: from hr2.samba.org ([144.76.82.148]:34113 "EHLO hr2.samba.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751599AbdBOQPg (ORCPT ); Wed, 15 Feb 2017 11:15:36 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=samba.org; s=42627210; h=Message-Id:Date:Cc:To:From; bh=NMsJNwGFNpbcIKcvOuraDkZTq0yOFfR6bJSjpSNV/p0=; b=qHlJbZZFef1TtbCdywUHEPXfgT LCprW+k00NuFz7CbuE1q+50XJ+ca5QTxP4uw1bgSLVdKHqYVj/J825mcVKKw0Vbh8xJ4xVmSQbn+4 Qmo/YqdUIoqKfHNRHSJEoOeqsnIGu7x1LSXKvwnIhfH2UeAdMgQ5LNbeAuSyaTqp42rY=; Received: from [127.0.0.2] (localhost [127.0.0.1]) by hr2.samba.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim) id 1ce2Ew-0006hm-Lh; Wed, 15 Feb 2017 16:15:34 +0000 From: Jeff Layton To: linux-cifs@vger.kernel.org, samba-technical@lists.samba.org Cc: cwseys@physics.wisc.edu, simo@redhat.com, samba@lists.samba.org Subject: [cifs-utils PATCH v4 1/4] cifs.upcall: convert two flags from int to bool Date: Wed, 15 Feb 2017 11:15:19 -0500 Message-Id: <20170215161522.17063-2-jlayton@samba.org> X-Mailer: git-send-email 2.9.3 In-Reply-To: <20170215161522.17063-1-jlayton@samba.org> References: <20170215161522.17063-1-jlayton@samba.org> Sender: linux-cifs-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-cifs@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Signed-off-by: Jeff Layton --- cifs.upcall.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/cifs.upcall.c b/cifs.upcall.c index 8f146c92b4a5..418b179d7f29 100644 --- a/cifs.upcall.c +++ b/cifs.upcall.c @@ -685,7 +685,8 @@ int main(const int argc, char *const argv[]) size_t datalen; unsigned int have; long rc = 1; - int c, try_dns = 0, legacy_uid = 0; + int c; + bool try_dns = false, legacy_uid = false; char *buf; char hostbuf[NI_MAXHOST], *host; struct decoded_args arg; @@ -705,7 +706,7 @@ int main(const int argc, char *const argv[]) /* legacy option -- skip it */ break; case 't': - try_dns++; + try_dns = true; break; case 'k': if (setenv("KRB5_CONFIG", optarg, 1) != 0) { @@ -717,7 +718,7 @@ int main(const int argc, char *const argv[]) keytab_name = optarg; break; case 'l': - legacy_uid++; + legacy_uid = true; break; case 'v': rc = 0; @@ -899,7 +900,7 @@ retry_new_hostname: if (rc) break; - try_dns = 0; + try_dns = false; host = hostbuf; goto retry_new_hostname; default: