From: Anthony Liguori <anthony@codemonkey.ws>
To: qemu-devel@nongnu.org
Subject: Re: [Qemu-devel] loadvm not working
Date: Thu, 25 Sep 2008 15:20:59 -0500 [thread overview]
Message-ID: <48DBF2AB.1010803@codemonkey.ws> (raw)
In-Reply-To: <da6318370809251307g301de870q2180840762953e2f@mail.gmail.com>
Piotras wrote:
> Hi,
>
> I discovered a bug that prevents loadvm from working correctly
> in current repository version (related to warning "qemu: warning:
> instance 0 of device '' not present in current VM").
> The implementation of functions qemu_get_be16 and qemu_get_be32
> (in file vl.c) relies on implicit conversion of signed byte
> (int8_t) values returned by qemu_get_byte to multi-byte integer
> types. When value to be converted is negative, the result is
> incorrect.
>
> There are two fixes possible:
>
> 1) change return type of qemu_get_byte to unsigned (uint8_t)
>
> 2) add explicit casts in qemu_get_be16 and qemu_get_be32
>
> For consistency with qemu_get_be16 and qemu_get_be32, first
> solution looks better. However I didn't examine all other calls
> to qemu_get_byte for possible problems.
>
Heh, I literally just debugged this myself :-) That patch that
introduced this is being reverted so it'll be fixed in a few hours.
Regards,
Anthony Liguori
> Hope this helps,
>
> Piotr
>
>
>
prev parent reply other threads:[~2008-09-25 20:22 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-09-25 20:07 [Qemu-devel] loadvm not working Piotras
2008-09-25 20:20 ` Anthony Liguori [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=48DBF2AB.1010803@codemonkey.ws \
--to=anthony@codemonkey.ws \
--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).