qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [PATCH v12 13/36] qapi: Hoist tag collision check to Va


From: Markus Armbruster
Subject: Re: [Qemu-devel] [PATCH v12 13/36] qapi: Hoist tag collision check to Variants.check()
Date: Wed, 18 Nov 2015 11:08:58 +0100
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.5 (gnu/linux)

Eric Blake <address@hidden> writes:

> *** WARNING: THE ATTACHED DOCUMENT(S) CONTAIN MACROS ***
> *** MACROS MAY CONTAIN MALICIOUS CODE ***
> *** Open only if you can verify and trust the sender ***
> *** Please contact address@hidden if you have questions or concerns **

Looks like infosec crapped over your commit message.

> Checking that a given QAPISchemaObjectTypeVariant.name is a
> member of the corresponding QAPISchemaEnumType of the owning
> QAPISchemaObjectTypeVariants.tag_member ensures that there are
> no collisions in the generated C union for those tag values
> (since the enum itself should have no collisions).
>
> However, ever since its introduction in f51d8c3d, this was the
> only additional action of of Variant.check(), beyond calling
> the superclass Member.check().  This forces a difference in
> .check() signatures, just to pass the enum type down.
>
> Simplify things by instead doing the tag name check as part of
> Variants.check(), at which point we can rely on inheritance
> instead of overriding Variant.check().
>
> Signed-off-by: Eric Blake <address@hidden>

Can bury the infosec turd on merge.



reply via email to

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