Message ID | 155148287716.16677.16342591325551254606.stgit@magnolia (mailing list archive) |
---|---|
State | Superseded, archived |
Headers | show
Return-Path: <linux-xfs-owner@kernel.org> Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 33BCE1575 for <patchwork-linux-xfs@patchwork.kernel.org>; Fri, 1 Mar 2019 23:28:01 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 1F4322F08A for <patchwork-linux-xfs@patchwork.kernel.org>; Fri, 1 Mar 2019 23:28:01 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 13A2D2F0C2; Fri, 1 Mar 2019 23:28:01 +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=-8.0 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,MAILING_LIST_MULTI,RCVD_IN_DNSWL_HI, UNPARSEABLE_RELAY 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 B05B72F0AF for <patchwork-linux-xfs@patchwork.kernel.org>; Fri, 1 Mar 2019 23:28:00 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726332AbfCAX2A (ORCPT <rfc822;patchwork-linux-xfs@patchwork.kernel.org>); Fri, 1 Mar 2019 18:28:00 -0500 Received: from userp2130.oracle.com ([156.151.31.86]:46450 "EHLO userp2130.oracle.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725996AbfCAX2A (ORCPT <rfc822;linux-xfs@vger.kernel.org>); Fri, 1 Mar 2019 18:28:00 -0500 Received: from pps.filterd (userp2130.oracle.com [127.0.0.1]) by userp2130.oracle.com (8.16.0.27/8.16.0.27) with SMTP id x21NOFRu123053 for <linux-xfs@vger.kernel.org>; Fri, 1 Mar 2019 23:27:59 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.com; h=subject : from : to : cc : date : message-id : in-reply-to : references : mime-version : content-type : content-transfer-encoding; s=corp-2018-07-02; bh=K5sMzxySs0XG7290aEJjjIBFxnryZu0HEpPADNhTox8=; b=WrhDu1O1KQ3IU97BiDCDo5tgNtEpkJcq1+m0BB76XI6SnkMHXic9he9s48/6RNCDxSkw lKu7CX8o3uzXKLMEgWCj+hRQFWqNd6P71znFz6JZB0PEkeL2hq2AP+vgPgX0jljtum8+ eE0/giBhioPZT/wfeS2/kn+pZ+kw3OTCoOyCmEKgXshPLwKrmL0VfUKQObNizm7DF8Y6 bb5eyLmYTk1cKBaoxraKtZK2E7UrVSvsVtX8z6wT0WQuHBtjATNWB6wVBRgtyrqIPSOP zi/FHi8Zi1rXVfcMohQq/mWbSsfWCgWIcS8Q89GCqZqa+0Rmflr2x1f+EIkuEoPFT8m5 Tg== Received: from userv0022.oracle.com (userv0022.oracle.com [156.151.31.74]) by userp2130.oracle.com with ESMTP id 2qtwkut90x-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK) for <linux-xfs@vger.kernel.org>; Fri, 01 Mar 2019 23:27:58 +0000 Received: from userv0122.oracle.com (userv0122.oracle.com [156.151.31.75]) by userv0022.oracle.com (8.14.4/8.14.4) with ESMTP id x21NRw1O032711 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK) for <linux-xfs@vger.kernel.org>; Fri, 1 Mar 2019 23:27:58 GMT Received: from abhmp0008.oracle.com (abhmp0008.oracle.com [141.146.116.14]) by userv0122.oracle.com (8.14.4/8.14.4) with ESMTP id x21NRwTQ021092 for <linux-xfs@vger.kernel.org>; Fri, 1 Mar 2019 23:27:58 GMT Received: from localhost (/10.159.229.175) by default (Oracle Beehive Gateway v4.0) with ESMTP ; Fri, 01 Mar 2019 15:27:58 -0800 Subject: [PATCH 10/23] xfs_scrub: don't close mnt_fd when mnt_fd open fails From: "Darrick J. Wong" <darrick.wong@oracle.com> To: darrick.wong@oracle.com Cc: linux-xfs@vger.kernel.org Date: Fri, 01 Mar 2019 15:27:57 -0800 Message-ID: <155148287716.16677.16342591325551254606.stgit@magnolia> In-Reply-To: <155148280859.16677.6057998944865066232.stgit@magnolia> References: <155148280859.16677.6057998944865066232.stgit@magnolia> User-Agent: StGit/0.17.1-dirty MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit X-Proofpoint-Virus-Version: vendor=nai engine=5900 definitions=9182 signatures=668685 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 priorityscore=1501 malwarescore=0 suspectscore=1 phishscore=0 bulkscore=0 spamscore=0 clxscore=1015 lowpriorityscore=0 mlxscore=0 impostorscore=0 mlxlogscore=928 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1810050000 definitions=main-1903010161 Sender: linux-xfs-owner@vger.kernel.org Precedence: bulk List-ID: <linux-xfs.vger.kernel.org> X-Mailing-List: linux-xfs@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP |
Series |
xfsprogs-5.0: fix various problems
|
expand
|
diff --git a/scrub/phase1.c b/scrub/phase1.c index 6b472147..04a5f4a9 100644 --- a/scrub/phase1.c +++ b/scrub/phase1.c @@ -59,9 +59,11 @@ xfs_cleanup_fs( if (ctx->datadev) disk_close(ctx->datadev); fshandle_destroy(); - error = close(ctx->mnt_fd); - if (error) - str_errno(ctx, _("closing mountpoint fd")); + if (ctx->mnt_fd >= 0) { + error = close(ctx->mnt_fd); + if (error) + str_errno(ctx, _("closing mountpoint fd")); + } fs_table_destroy(); return true;