[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH RESEND v4 1/5] qom: split object_property_set_li
From: |
Andreas Färber |
Subject: |
Re: [Qemu-devel] [PATCH RESEND v4 1/5] qom: split object_property_set_link() |
Date: |
Wed, 19 Mar 2014 22:16:35 +0100 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:24.0) Gecko/20100101 Thunderbird/24.3.0 |
Am 19.03.2014 08:58, schrieb Stefan Hajnoczi:
> The path resolution logic in object_property_set_link() should be a
> separate function. This makes the code easier to read and maintain.
>
> Signed-off-by: Stefan Hajnoczi <address@hidden>
> ---
> qom/object.c | 59 +++++++++++++++++++++++++++++++++++++++--------------------
> 1 file changed, 39 insertions(+), 20 deletions(-)
>
> diff --git a/qom/object.c b/qom/object.c
> index a2a1ffa..da49474 100644
> --- a/qom/object.c
> +++ b/qom/object.c
> @@ -1039,17 +1039,49 @@ static void object_get_link_property(Object *obj,
> Visitor *v, void *opaque,
> }
> }
>
> +/* object_resolve_link:
I've taken the liberty to adopt the recommended style for non-header
gtk-doc comments here, using a single /* rather than /** line.
Andreas
> + *
> + * Lookup an object and ensure its type matches the link property type. This
> + * is similar to object_resolve_path() except type verification against the
> + * link property is performed.
> + *
> + * Returns: The matched object or NULL on path lookup failures.
> + */
> +static Object *object_resolve_link(Object *obj, const char *name,
> + const char *path, Error **errp)
[snip]
--
SUSE LINUX Products GmbH, Maxfeldstr. 5, 90409 Nürnberg, Germany
GF: Jeff Hawn, Jennifer Guild, Felix Imendörffer; HRB 16746 AG Nürnberg
- [Qemu-devel] [PATCH RESEND v4 0/5] qom: link property fixes, Stefan Hajnoczi, 2014/03/19
- [Qemu-devel] [PATCH RESEND v4 1/5] qom: split object_property_set_link(), Stefan Hajnoczi, 2014/03/19
- Re: [Qemu-devel] [PATCH RESEND v4 1/5] qom: split object_property_set_link(),
Andreas Färber <=
- [Qemu-devel] [PATCH RESEND v4 3/5] qom: make QOM link property unref optional, Stefan Hajnoczi, 2014/03/19
- [Qemu-devel] [PATCH RESEND v4 4/5] qom: add check() argument to object_property_add_link(), Stefan Hajnoczi, 2014/03/19
- [Qemu-devel] [PATCH RESEND v4 5/5] virtio-rng: avoid default_backend refcount leak, Stefan Hajnoczi, 2014/03/19
- [Qemu-devel] [PATCH RESEND v4 2/5] qom: don't make link NULL on object_property_set_link() failure, Stefan Hajnoczi, 2014/03/19
- Re: [Qemu-devel] [PATCH RESEND v4 0/5] qom: link property fixes, Paolo Bonzini, 2014/03/19