From patchwork Tue Sep 8 13:16:51 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Zhaolei X-Patchwork-Id: 7140971 Return-Path: X-Original-To: patchwork-linux-btrfs@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork2.web.kernel.org (Postfix) with ESMTP id 1825DBEEC1 for ; Tue, 8 Sep 2015 13:18:41 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 55E5F20646 for ; Tue, 8 Sep 2015 13:18:40 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id BBE82206E4 for ; Tue, 8 Sep 2015 13:18:38 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754732AbbIHNSf (ORCPT ); Tue, 8 Sep 2015 09:18:35 -0400 Received: from cn.fujitsu.com ([59.151.112.132]:2443 "EHLO heian.cn.fujitsu.com" rhost-flags-OK-FAIL-OK-FAIL) by vger.kernel.org with ESMTP id S1753566AbbIHNSc (ORCPT ); Tue, 8 Sep 2015 09:18:32 -0400 X-IronPort-AV: E=Sophos;i="5.15,520,1432569600"; d="scan'208";a="100473619" Received: from bogon (HELO edo.cn.fujitsu.com) ([10.167.33.5]) by heian.cn.fujitsu.com with ESMTP; 08 Sep 2015 21:21:28 +0800 Received: from G08CNEXCHPEKD01.g08.fujitsu.local (localhost.localdomain [127.0.0.1]) by edo.cn.fujitsu.com (8.14.3/8.13.1) with ESMTP id t88DIHm0018031 for ; Tue, 8 Sep 2015 21:18:17 +0800 Received: from localhost.localdomain (10.167.226.114) by G08CNEXCHPEKD01.g08.fujitsu.local (10.167.33.89) with Microsoft SMTP Server id 14.3.181.6; Tue, 8 Sep 2015 21:18:29 +0800 From: Zhao Lei To: CC: Zhao Lei Subject: [PATCH 3/3] btrfs-progs: add ext2fs_close_inode_scan to copy_inodes Date: Tue, 8 Sep 2015 21:16:51 +0800 Message-ID: <8ed299639db87f1026ecc444f952c439412230eb.1441718128.git.zhaolei@cn.fujitsu.com> X-Mailer: git-send-email 1.8.5.1 In-Reply-To: References: MIME-Version: 1.0 Sender: linux-btrfs-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-btrfs@vger.kernel.org X-Spam-Status: No, score=-6.9 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, T_RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP We need use ext2fs_close_inode_scan to release relative resource get from ext2fs_open_inode_scan() in copy_inodes() Signed-off-by: Zhao Lei --- btrfs-convert.c | 1 + 1 file changed, 1 insertion(+) diff --git a/btrfs-convert.c b/btrfs-convert.c index 934f4dc..e7f3c9e 100644 --- a/btrfs-convert.c +++ b/btrfs-convert.c @@ -1186,6 +1186,7 @@ static int copy_inodes(struct btrfs_root *root, ext2_filsys ext2_fs, } ret = btrfs_commit_transaction(trans, root); BUG_ON(ret); + ext2fs_close_inode_scan(ext2_scan); return ret; }