qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [PATCH v3 23/26] qapi: Make input visitors detect unvis


From: Eric Blake
Subject: Re: [Qemu-devel] [PATCH v3 23/26] qapi: Make input visitors detect unvisited list tails
Date: Tue, 28 Feb 2017 12:38:01 -0600
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.7.0

On 02/28/2017 11:39 AM, Markus Armbruster wrote:
> Fix the design flaw demonstrated in the previous commit: new method
> check_list() lets input visitors report that unvisited input remains
> for a list, exactly like check_struct() lets them report that
> unvisited input remains for a struct or union.
> 
> Implement the method for the qobject input visitor (straightforward),
> and the string input visitor (less so, due to the magic list syntax
> there).  The opts visitor's list magic is even more impenetrable, and
> all I can do there today is a stub with a FIXME comment.  No worse
> than before.
> 
> Signed-off-by: Markus Armbruster <address@hidden>
> ---

> +++ b/hw/ppc/spapr_drc.c
> @@ -326,7 +326,12 @@ static void prop_get_fdt(Object *obj, Visitor *v, const 
> char *name,
>                      return;
>                  }
>              }
> +            visit_check_list(v, &err);
>              visit_end_list(v, NULL);
> +            if (err) {
> +                error_propagate(errp, err);
> +                return;
> +            }
>              break;
>          }

Better. Thanks for the fast respin.

Reviewed-by: Eric Blake <address@hidden>

-- 
Eric Blake   eblake redhat com    +1-919-301-3266
Libvirt virtualization library http://libvirt.org

Attachment: signature.asc
Description: OpenPGP digital signature


reply via email to

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