Received: from eggs.gnu.org ([2001:4830:134:3::10]:59366) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VHvmI-0004I4-Hi for qemu-devel@nongnu.org; Fri, 06 Sep 2013 09:08:52 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1VHvmC-0003s6-Fs for qemu-devel@nongnu.org; Fri, 06 Sep 2013 09:08:46 -0400 Received: from mx1.redhat.com ([209.132.183.28]:7288) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VHvmC-0003ra-8F for qemu-devel@nongnu.org; Fri, 06 Sep 2013 09:08:40 -0400 Received: from int-mx11.intmail.prod.int.phx2.redhat.com (int-mx11.intmail.prod.int.phx2.redhat.com [10.5.11.24]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id r86D8dol022219 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Fri, 6 Sep 2013 09:08:39 -0400 Date: Fri, 6 Sep 2013 15:08:36 +0200 From: Kevin Wolf Message-ID: <20130906130836.GI2588@dhcp-200-207.str.redhat.com> References: <1378389342-4749-1-git-send-email-mreitz@redhat.com> <1378389342-4749-2-git-send-email-mreitz@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1378389342-4749-2-git-send-email-mreitz@redhat.com> Subject: Re: [Qemu-devel] [RFC v2 1/6] bdrv: Use "Error" for opening images List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Max Reitz Cc: qemu-devel@nongnu.org, Stefan Hajnoczi Am 05.09.2013 um 15:55 hat Max Reitz geschrieben: > Add an Error ** parameter to BlockDriver.bdrv_open and > BlockDriver.bdrv_file_open to allow more specific error messages. > > Signed-off-by: Max Reitz > diff --git a/block/raw_bsd.c b/block/raw_bsd.c > index ab2b0fd..793121a 100644 > --- a/block/raw_bsd.c > +++ b/block/raw_bsd.c > @@ -130,12 +130,14 @@ static int raw_has_zero_init(BlockDriverState *bs) > return bdrv_has_zero_init(bs->file); > } > > -static int raw_create(const char *filename, QEMUOptionParameter *options) > +static int raw_create(const char *filename, QEMUOptionParameter *options, > + Error **errp) > { > return bdrv_create_file(filename, options); > } > > -static int raw_open(BlockDriverState *bs, QDict *options, int flags) > +static int raw_open(BlockDriverState *bs, QDict *options, int flags, > + Error **errp) > { > bs->sg = bs->file->sg; > return 0; raw_create() shouldn't be converted in this patch, this causes a build failure. Kevin