From: Max Reitz <mreitz@redhat.com>
To: Jeff Cody <jcody@redhat.com>, qemu-devel@nongnu.org
Cc: kwolf@redhat.com, pbonzini@redhat.com, famz@redhat.com,
stefanha@redhat.com
Subject: Re: [Qemu-devel] [PATCH] block: vmdk - fixed sizeof() error
Date: Tue, 10 Feb 2015 16:42:14 -0500 [thread overview]
Message-ID: <54DA7B36.90801@redhat.com> (raw)
In-Reply-To: <46d873261433f4527e88885582f96942d61758d6.1423592487.git.jcody@redhat.com>
On 2015-02-10 at 13:22, Jeff Cody wrote:
> The size compared should be PATH_MAX, rather than sizeof(char *).
>
> Reported-by: Paolo Bonzini <pbonzini@redhat.com>
> Signed-off-by: Jeff Cody <jcody@redhat.com>
> ---
> block/vmdk.c | 3 +--
> 1 file changed, 1 insertion(+), 2 deletions(-)
I just noticed iotest 059 failing, bisected it and the changeset of the
commit in question looked strangely related to a patch I seemed to
recall having seen on qemu-devel today... :-)
Reviewed-by: Max Reitz <mreitz@redhat.com>
> diff --git a/block/vmdk.c b/block/vmdk.c
> index 7d079ad..8410a15 100644
> --- a/block/vmdk.c
> +++ b/block/vmdk.c
> @@ -843,8 +843,7 @@ static int vmdk_parse_extents(const char *desc, BlockDriverState *bs,
> }
>
> extent_path = g_malloc0(PATH_MAX);
> - path_combine(extent_path, sizeof(extent_path),
> - desc_file_path, fname);
> + path_combine(extent_path, PATH_MAX, desc_file_path, fname);
> extent_file = NULL;
> ret = bdrv_open(&extent_file, extent_path, NULL, NULL,
> bs->open_flags | BDRV_O_PROTOCOL, NULL, errp);
next prev parent reply other threads:[~2015-02-10 21:42 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-02-10 18:22 [Qemu-devel] [PATCH] block: vmdk - fixed sizeof() error Jeff Cody
2015-02-10 21:10 ` Eric Blake
2015-02-10 21:42 ` Max Reitz [this message]
2015-02-12 17:15 ` Stefan Hajnoczi
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=54DA7B36.90801@redhat.com \
--to=mreitz@redhat.com \
--cc=famz@redhat.com \
--cc=jcody@redhat.com \
--cc=kwolf@redhat.com \
--cc=pbonzini@redhat.com \
--cc=qemu-devel@nongnu.org \
--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).