From patchwork Mon Nov 6 13:10:46 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Chandan Babu R X-Patchwork-Id: 13446920 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 05284C4167D for ; Mon, 6 Nov 2023 13:13:10 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232187AbjKFNNK (ORCPT ); Mon, 6 Nov 2023 08:13:10 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:52172 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232143AbjKFNNG (ORCPT ); Mon, 6 Nov 2023 08:13:06 -0500 Received: from mx0a-00069f02.pphosted.com (mx0a-00069f02.pphosted.com [205.220.165.32]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 7BA8D125 for ; Mon, 6 Nov 2023 05:13:00 -0800 (PST) Received: from pps.filterd (m0333521.ppops.net [127.0.0.1]) by mx0b-00069f02.pphosted.com (8.17.1.19/8.17.1.19) with ESMTP id 3A6D2AEY006802; Mon, 6 Nov 2023 13:12:58 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.com; h=from : to : cc : subject : date : message-id : in-reply-to : references : content-transfer-encoding : content-type : mime-version; s=corp-2023-03-30; bh=Eo2H4ZdqcZj1h9U9KJV5dXdRK4RG40qHiLn0E+r57ns=; b=k9+mjxxIKbX6Qhzmb9dVC2kqTzofCdx4KOEesbF4pCz8Kv9BfMcq2gk0LMmEdBZFyzEs LaycCPbblj+Llu1D7sW5igtE8MHB4nF39aDVNofFqZqBaKGX6FIoyM2knV5BGPw+1zfN IBJsSs6QA9eZDCmFRlP/RWbeRUDbkttniRuolMnggAop8GR5bPu25hgY1TCATr/kRNv+ NOc3BLwc++0TGm2YaUXUqdzAA1ThaKEF/cCX41C3rYOiElcCcLDRjngeS9mWb3/BbBev 3YotHfVLBvCUF+A+Nvrv3qd1qmJq8YxGYM/M92z4Qxkk2NHZ6sZA9B8XguDvdUZ9JZP1 JA== Received: from phxpaimrmta01.imrmtpd1.prodappphxaev1.oraclevcn.com (phxpaimrmta01.appoci.oracle.com [138.1.114.2]) by mx0b-00069f02.pphosted.com (PPS) with ESMTPS id 3u5cvcb08m-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Mon, 06 Nov 2023 13:12:58 +0000 Received: from pps.filterd (phxpaimrmta01.imrmtpd1.prodappphxaev1.oraclevcn.com [127.0.0.1]) by phxpaimrmta01.imrmtpd1.prodappphxaev1.oraclevcn.com (8.17.1.19/8.17.1.19) with ESMTP id 3A6D8Rjj023535; Mon, 6 Nov 2023 13:12:57 GMT Received: from nam11-dm6-obe.outbound.protection.outlook.com (mail-dm6nam11lp2168.outbound.protection.outlook.com [104.47.57.168]) by phxpaimrmta01.imrmtpd1.prodappphxaev1.oraclevcn.com (PPS) with ESMTPS id 3u5cd4tcfa-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Mon, 06 Nov 2023 13:12:57 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=HM26XDAceA5WbYCWCB16kc6qDVSZcndacVeaPRhw+57JDyunnM+YESYlgIQcE5+Bm8Y01xZuyO+9HiEw33wx1eoVxfKT5ywo5+lWo3gCV7hpxDmJE/9QjuB7uenLsIKB3VHTf2ESyWk3br83+X3xVbYAUIivd21dxncHprU5JkKLh+sPM2/IWwBbSp2GTfSu6Tya4PPuXSSz/GdNC3c2a11H1XgnBAFS9W7FfrresoC+crGIMJpv0OV3jyPXeA/Qgwa2efiWr9X75h6kKSj39D1K+8csnu4T40QNkBntxc4meO8JSHrFGw2hEZgMwZR+1KlBSYGcM26S4SnUYfLlVA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=Eo2H4ZdqcZj1h9U9KJV5dXdRK4RG40qHiLn0E+r57ns=; b=e+CWMQY/9L5NmgpkhWXwgiEJXddfBDsPpLU1bMTDWp/kUXhcQGV7eDSOP/hVSyhRHTLnN8nZxRpCJR13DdhSZr1sduJz1qwqU36WXEdPJOLXuQzIcLEMOVFL/17dAZFnH1LWhGSqybX/h4L85B7L7Jyc517McO6xSqTavt4jga61Ml8xk+m9wmYxSP16n453eUrCU536ziOO8Eisqq0KKdR0UTRRlSHBraLhQ7RQ3NiyfOFMX0cty3wppQ6hd80N1oFx0roktSq5Aq7pc8K76ve1CGlpbK4M0YFbDzKnU2zddJyjSssoFuToKvUd6Ul/jWtutx7Jj8Nnns3cwJ66dw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=oracle.com; dmarc=pass action=none header.from=oracle.com; dkim=pass header.d=oracle.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.onmicrosoft.com; s=selector2-oracle-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=Eo2H4ZdqcZj1h9U9KJV5dXdRK4RG40qHiLn0E+r57ns=; b=Vs06s6VxSrNlUU5cM+b/IbncFMlvIwTkiTjP1GgMwBgevwZpecfaSozanFqUapNDUASxJrnJ1lZskeM7/MARQxo2qgxBoNZXhwqV6Ep+9qvqV344fO14+Z+OsCzkwEiGE7/blqrrauwYGwSTXU96+M1trb3mLJFA7gDBWd3gJ5Q= Received: from SA1PR10MB5867.namprd10.prod.outlook.com (2603:10b6:806:233::19) by CO1PR10MB4513.namprd10.prod.outlook.com (2603:10b6:303:93::23) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6954.28; Mon, 6 Nov 2023 13:12:23 +0000 Received: from SA1PR10MB5867.namprd10.prod.outlook.com ([fe80::9bf4:a5ad:d9cd:f62d]) by SA1PR10MB5867.namprd10.prod.outlook.com ([fe80::9bf4:a5ad:d9cd:f62d%3]) with mapi id 15.20.6954.028; Mon, 6 Nov 2023 13:12:22 +0000 From: Chandan Babu R To: linux-xfs@vger.kernel.org Cc: Chandan Babu R , djwong@kernel.org, cem@kernel.org Subject: [PATCH V4 13/21] mdrestore: Declare boolean variables with bool type Date: Mon, 6 Nov 2023 18:40:46 +0530 Message-Id: <20231106131054.143419-14-chandan.babu@oracle.com> X-Mailer: git-send-email 2.39.1 In-Reply-To: <20231106131054.143419-1-chandan.babu@oracle.com> References: <20231106131054.143419-1-chandan.babu@oracle.com> X-ClientProxiedBy: SG2PR04CA0181.apcprd04.prod.outlook.com (2603:1096:4:14::19) To SA1PR10MB5867.namprd10.prod.outlook.com (2603:10b6:806:233::19) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: SA1PR10MB5867:EE_|CO1PR10MB4513:EE_ X-MS-Office365-Filtering-Correlation-Id: 49014c4f-3204-458e-5498-08dbdeca037a X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: lGsOxKqOVUqfcDrPve3sqCSRpQtNhZNRU3JQy27vn6HuTh0ucRCvhCuIMUXfl7j3TNRJjsTP1uEKR15GykaGkeBUK5tigGwUP31rezHGKS2POmPv54bkyJlKuAonWidQ1gyJsYzohzCEI6/2pTUq+1+/uadztNHAnTDab/alUBcmQwf8tDJXXL+FstG8YhTuITFsrIbTf+OF7+za5AskDOMSaoyHxJvJCpspHPKex9PNpvPT5Ph7Wbd/AtzLaM6738icJ3HkBkrnxHGrYpKejzzD7OEO9RAZNrRKCrRaQWASrnNa47QsGIxzqKd1a6Jn9G8dNR1Ar3LsyAEIsGsNRCvibOV1WIZ7pBSxrVhxqRBAVSgCbxOsX+Hyiotm7gZoLl97o+iAAWJ0EIqf/lGlf5kGzeiDRPwogfTeNFuuZWYuSuGynS/4BUVQGJij+ThZsz6yEaoOvskxP3yywangy8nVOUhAHxUeOLTuKNinHVy96qF74naNdgZpMbrqUT/7VuPCvD9T2To7Yx9VSLLxgSQwn4AU4eZ/ww49WlxiYYAeJB9D7d67nvmslmkMyzCWd0u82XrZzgnCs++woPOnAtrOvBjcFXCETIQ0wgdF3k0hIRJ/FibpZMgRHlanqN3R X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:SA1PR10MB5867.namprd10.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230031)(376002)(136003)(346002)(39860400002)(366004)(396003)(230273577357003)(230922051799003)(230173577357003)(186009)(1800799009)(64100799003)(451199024)(6512007)(41300700001)(6486002)(66476007)(66946007)(66556008)(6666004)(478600001)(5660300002)(6506007)(1076003)(4326008)(8676002)(6916009)(8936002)(316002)(2616005)(26005)(2906002)(83380400001)(38100700002)(36756003)(86362001);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: E1fRuRCf3q4jq3Zci9YIhsvzTuIXeTEbF560AurqLjsO/g2BtEj+d0epXBQwLvy8CN9e40Q/SMd8Iofj0Bi2FJb5meSLiS6PfwoIL3mAnHHr9jOLKKxEz+f50uAFri29bEuovTzg30sH+TWF8tmkbSKtvXH+YEvX2K32W5VLsqkY/P0v7wROZ9JT9EAJ/lXIgPeo/x0KxQciVNTd4fUx9wkd3qm/BaEPN+MuiJYz7ch9vwlQUvdVNxf8oQDTNV9RKrb+amiYRV71jKeFDB0k7Tsr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Vti0fKWGXPddSGC6/boAOAoDE+lFlPoD5YzMu18AQ523JTMB2nn2S30mp7kB6aqUl5XNJh2h3P/TRTRYR4= X-OriginatorOrg: oracle.com X-MS-Exchange-CrossTenant-Network-Message-Id: 49014c4f-3204-458e-5498-08dbdeca037a X-MS-Exchange-CrossTenant-AuthSource: SA1PR10MB5867.namprd10.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 06 Nov 2023 13:12:22.9155 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 4e2c6054-71cb-48f1-bd6c-3a9705aca71b X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: 6Xve98O7GydvlO+ScK12o1r/7GOfRwQ5SI39/PjPDNFPzGfSt0AfC2Ureatxsecy9/Yz8TxV/cXFNCbmqtTJLg== X-MS-Exchange-Transport-CrossTenantHeadersStamped: CO1PR10MB4513 X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.272,Aquarius:18.0.987,Hydra:6.0.619,FMLib:17.11.176.26 definitions=2023-11-06_12,2023-11-02_03,2023-05-22_02 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 bulkscore=0 mlxscore=0 adultscore=0 suspectscore=0 phishscore=0 spamscore=0 mlxlogscore=999 malwarescore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2310240000 definitions=main-2311060106 X-Proofpoint-GUID: 6ZsshsMpqPoX-UmVUE0sU8AJy9UlJDV6 X-Proofpoint-ORIG-GUID: 6ZsshsMpqPoX-UmVUE0sU8AJy9UlJDV6 Precedence: bulk List-ID: X-Mailing-List: linux-xfs@vger.kernel.org Reviewed-by: Darrick J. Wong Signed-off-by: Chandan Babu R --- mdrestore/xfs_mdrestore.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/mdrestore/xfs_mdrestore.c b/mdrestore/xfs_mdrestore.c index 481dd00c..ca28c48e 100644 --- a/mdrestore/xfs_mdrestore.c +++ b/mdrestore/xfs_mdrestore.c @@ -7,9 +7,9 @@ #include "libxfs.h" #include "xfs_metadump.h" -static int show_progress = 0; -static int show_info = 0; -static int progress_since_warning = 0; +static bool show_progress = false; +static bool show_info = false; +static bool progress_since_warning = false; static void fatal(const char *msg, ...) @@ -35,7 +35,7 @@ print_progress(const char *fmt, ...) printf("\r%-59s", buf); fflush(stdout); - progress_since_warning = 1; + progress_since_warning = true; } /* @@ -202,10 +202,10 @@ main( while ((c = getopt(argc, argv, "giV")) != EOF) { switch (c) { case 'g': - show_progress = 1; + show_progress = true; break; case 'i': - show_info = 1; + show_info = true; break; case 'V': printf("%s version %s\n", progname, VERSION);