From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([208.118.235.92]:39686) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UVMRW-0000Vu-Vf for qemu-devel@nongnu.org; Thu, 25 Apr 2013 09:42:36 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UVMRS-0003LF-BY for qemu-devel@nongnu.org; Thu, 25 Apr 2013 09:42:34 -0400 Received: from mail-we0-x22b.google.com ([2a00:1450:400c:c03::22b]:61550) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UVMRS-0003Kn-5G for qemu-devel@nongnu.org; Thu, 25 Apr 2013 09:42:30 -0400 Received: by mail-we0-f171.google.com with SMTP id t57so709740wey.30 for ; Thu, 25 Apr 2013 06:42:29 -0700 (PDT) Date: Thu, 25 Apr 2013 15:42:22 +0200 From: Stefan Hajnoczi Message-ID: <20130425134222.GD10819@stefanha-thinkpad.redhat.com> References: <8b6851c3a59103d7dd55ae400be90e6d7431ab0b.1366817130.git.phrdina@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <8b6851c3a59103d7dd55ae400be90e6d7431ab0b.1366817130.git.phrdina@redhat.com> Subject: Re: [Qemu-devel] [PATCH v2 02/12] block: update error reporting for bdrv_snapshot_delete() and related functions List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Pavel Hrdina Cc: kwolf@redhat.com, armbru@redhat.com, qemu-devel@nongnu.org, lcapitulino@redhat.com, xiawenc@linux.vnet.ibm.com, MORITA Kazutaka On Wed, Apr 24, 2013 at 05:32:00PM +0200, Pavel Hrdina wrote: > diff --git a/block/sheepdog.c b/block/sheepdog.c > index 20b5d06..7e0610f 100644 > --- a/block/sheepdog.c > +++ b/block/sheepdog.c > @@ -1937,10 +1937,12 @@ out: > return ret; > } > > -static int sd_snapshot_delete(BlockDriverState *bs, const char *snapshot_id) > +static void sd_snapshot_delete(BlockDriverState *bs, > + const char *snapshot_id, > + Error **errp) > { > /* FIXME: Delete specified snapshot id. */ > - return 0; > + error_setg(errp, "Deleting snapshot is not supported"); > } Careful, this could break existing tests or applications that expect snapshot delete to lie. I suggest *not* setting the error for now, unless Kazutaka agrees it's okay to start erroring now.