qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Chen Gang <gang.chen.5i5j@gmail.com>
To: Stefan Hajnoczi <stefanha@gmail.com>
Cc: kwolf@redhat.com, qemu-trivial@nongnu.org,
	Michael Tokarev <mjt@tls.msk.ru>,
	qemu-devel@nongnu.org, stefanha@redhat.com
Subject: Re: [Qemu-devel] [PATCH trivial] block.c: Correct the return value and the failure object when failure occurs
Date: Mon, 23 Jun 2014 23:08:08 +0800	[thread overview]
Message-ID: <53A842D8.1040204@gmail.com> (raw)
In-Reply-To: <20140623073806.GB13485@stefanha-thinkpad.redhat.com>

On 06/23/2014 03:38 PM, Stefan Hajnoczi wrote:
> 
> The return value of bdrv_open() is a negative errno.  -1 does not make
> sense in this case.
> 
> Please add an int return value to bdrv_append_temp_snapshot() so the
> caller can determine the real errno.  Then the remainder of the patch
> can be:
> 
>      if (snapshot_flags) {
> -        bdrv_append_temp_snapshot(bs, snapshot_flags, &local_err);
> +        ret = bdrv_append_temp_snapshot(bs, snapshot_flags, &local_err);
>          if (local_err) {
> -            error_propagate(errp, local_err);
>              goto close_and_fail;
>          }
>      }
> 

That's fine to me, I shall send patch v2 for it.

Thanks.
-- 
Chen Gang

Open share and attitude like air water and life which God blessed

      reply	other threads:[~2014-06-23 15:09 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-06-21 14:59 [Qemu-devel] [PATCH trivial] block.c: Correct the return value and the failure object when failure occurs Chen Gang
2014-06-23  7:38 ` Stefan Hajnoczi
2014-06-23 15:08   ` Chen Gang [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=53A842D8.1040204@gmail.com \
    --to=gang.chen.5i5j@gmail.com \
    --cc=kwolf@redhat.com \
    --cc=mjt@tls.msk.ru \
    --cc=qemu-devel@nongnu.org \
    --cc=qemu-trivial@nongnu.org \
    --cc=stefanha@gmail.com \
    --cc=stefanha@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).