qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Miguel Di Ciurcio Filho <miguel.filho@gmail.com>
To: Kevin Wolf <kwolf@redhat.com>
Cc: qemu-devel@nongnu.org
Subject: [Qemu-devel] Re: [PATCH v3] savevm: Really verify if a drive supports snapshots
Date: Fri, 4 Jun 2010 14:46:43 -0300	[thread overview]
Message-ID: <AANLkTimLLIEvRCAiKqm1byu4yp9rXsEhxyFtWqcmRs8m@mail.gmail.com> (raw)
In-Reply-To: <4C0937D4.3010607@redhat.com>

On Fri, Jun 4, 2010 at 2:28 PM, Kevin Wolf <kwolf@redhat.com> wrote:
>> @@ -1674,12 +1659,26 @@ void do_savevm(Monitor *mon, const QDict *qdict)
>>  #endif
>>      const char *name = qdict_get_try_str(qdict, "name");
>>
>> +    /* Verify if there is a device that doesn't support snapshots and is writable */
>> +    QTAILQ_FOREACH(dinfo, &drives, next) {
>> +        bs = dinfo->bdrv;
>> +
>> +        if (bdrv_is_removable(bs) || bdrv_is_read_only(bs)) {
>> +            continue;
>> +        }
>> +
>> +        if (!bdrv_can_snapshot(bs)) {
>> +            monitor_printf(mon, "Device '%s' is writable but does not support snapshots.\n",
>> +                               bdrv_get_device_name(bs));
>> +            goto the_end;
>
> cc1: warnings being treated as errors
> savevm.c: In Funktion »do_savevm«:
> savevm.c:1654: Fehler: »saved_vm_running« may be used uninitialized in
> this function
>
> return instead of goto the_end is probably the right thing to do here.
>

Strange. This warning did not happen with me.

Miguel

      reply	other threads:[~2010-06-04 17:49 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-06-03 19:52 [Qemu-devel] [PATCH v3] savevm: Really verify if a drive supports snapshots Miguel Di Ciurcio Filho
2010-06-04 13:57 ` [Qemu-devel] " Kevin Wolf
2010-06-04 17:28 ` Kevin Wolf
2010-06-04 17:46   ` Miguel Di Ciurcio Filho [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=AANLkTimLLIEvRCAiKqm1byu4yp9rXsEhxyFtWqcmRs8m@mail.gmail.com \
    --to=miguel.filho@gmail.com \
    --cc=kwolf@redhat.com \
    --cc=qemu-devel@nongnu.org \
    /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).