From patchwork Fri Sep 11 04:05:36 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Zheng Bin X-Patchwork-Id: 11769755 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 12EC413B1 for ; Fri, 11 Sep 2020 03:59:28 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 03A812078D for ; Fri, 11 Sep 2020 03:59:27 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1725787AbgIKD66 (ORCPT ); Thu, 10 Sep 2020 23:58:58 -0400 Received: from szxga06-in.huawei.com ([45.249.212.32]:59430 "EHLO huawei.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1725780AbgIKD64 (ORCPT ); Thu, 10 Sep 2020 23:58:56 -0400 Received: from DGGEMS406-HUB.china.huawei.com (unknown [172.30.72.60]) by Forcepoint Email with ESMTP id 53D8CB045BE2E1C82452; Fri, 11 Sep 2020 11:58:54 +0800 (CST) Received: from huawei.com (10.90.53.225) by DGGEMS406-HUB.china.huawei.com (10.3.19.206) with Microsoft SMTP Server id 14.3.487.0; Fri, 11 Sep 2020 11:58:45 +0800 From: Zheng Bin To: , , , CC: , Subject: [PATCH -next 2/5] cifs: fix comparison to bool warning in file.c Date: Fri, 11 Sep 2020 12:05:36 +0800 Message-ID: <20200911040539.113307-3-zhengbin13@huawei.com> X-Mailer: git-send-email 2.26.0.106.g9fadedd In-Reply-To: <20200911040539.113307-1-zhengbin13@huawei.com> References: <20200911040539.113307-1-zhengbin13@huawei.com> MIME-Version: 1.0 X-Originating-IP: [10.90.53.225] X-CFilter-Loop: Reflected Sender: linux-cifs-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-cifs@vger.kernel.org Fixes coccicheck warning: fs/cifs/file.c:780:22-38: WARNING: Comparison to bool Signed-off-by: Zheng Bin --- fs/cifs/file.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -- 2.26.0.106.g9fadedd diff --git a/fs/cifs/file.c b/fs/cifs/file.c index be46fab4c96d..bad749f606d5 100644 --- a/fs/cifs/file.c +++ b/fs/cifs/file.c @@ -777,7 +777,7 @@ cifs_reopen_file(struct cifsFileInfo *cfile, bool can_flush) * not dirty locally we could do this. */ rc = server->ops->open(xid, &oparms, &oplock, NULL); - if (rc == -ENOENT && oparms.reconnect == false) { + if (rc == -ENOENT && !oparms.reconnect) { /* durable handle timeout is expired - open the file again */ rc = server->ops->open(xid, &oparms, &oplock, NULL); /* indicate that we need to relock the file */