qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH v2 3/4] qcow2: Tighten cluster_offset alignment assertions


From: Alberto Garcia
Subject: Re: [PATCH v2 3/4] qcow2: Tighten cluster_offset alignment assertions
Date: Fri, 10 Jan 2020 13:14:45 +0100
User-agent: Notmuch/0.18.2 (http://notmuchmail.org) Emacs/24.4.1 (i586-pc-linux-gnu)

On Thu 09 Jan 2020 08:13:01 PM CET, Alberto Garcia wrote:
> -        assert((cluster_offset & 511) == 0);
> +        assert(QEMU_IS_ALIGNED(cluster_offset, s->cluster_size));

On second thoughts this patch could also use the (probably more
efficient) offset_into_cluster() call instead.

I can resend it if you think it's a good idea.

Berto



reply via email to

[Prev in Thread] Current Thread [Next in Thread]