From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:49388) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1W8VO2-0001pN-T8 for qemu-devel@nongnu.org; Wed, 29 Jan 2014 08:41:08 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1W8VNw-0001RH-Ui for qemu-devel@nongnu.org; Wed, 29 Jan 2014 08:41:02 -0500 Received: from mx1.redhat.com ([209.132.183.28]:39692) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1W8VNw-0001R7-N7 for qemu-devel@nongnu.org; Wed, 29 Jan 2014 08:40:56 -0500 Received: from int-mx01.intmail.prod.int.phx2.redhat.com (int-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.11]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id s0TDetob009119 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Wed, 29 Jan 2014 08:40:56 -0500 Date: Wed, 29 Jan 2014 14:40:53 +0100 From: Kevin Wolf Message-ID: <20140129134053.GI2726@dhcp-200-207.str.redhat.com> References: <1390762963-25538-1-git-send-email-mreitz@redhat.com> <1390762963-25538-8-git-send-email-mreitz@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1390762963-25538-8-git-send-email-mreitz@redhat.com> Subject: Re: [Qemu-devel] [PATCH 07/10] block: Reuse fail path from bdrv_open() List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Max Reitz Cc: qemu-devel@nongnu.org, Stefan Hajnoczi Am 26.01.2014 um 20:02 hat Max Reitz geschrieben: > The fail paths of bdrv_file_open() and bdrv_open() naturally exhibit > similarities, thus it is possible to reuse the one from bdrv_open() and > shorten the one in bdrv_file_open() accordingly. > > Signed-off-by: Max Reitz I find this change confusing because it is bdrv_file_open() that takes ownership of bs->options and assigns it. So I think it should be bdrv_file_open() that frees it again in failure cases. Kevin