All of lore.kernel.org
 help / color / mirror / Atom feed
From: Andrew Cooper <andrew.cooper3@citrix.com>
To: Ian Campbell <ian.campbell@citrix.com>
Cc: ian.jackson@eu.citrix.com, xen-devel@lists.xen.org
Subject: Re: [PATCH] tools: libxl: testidl: initialise the KeyedUnion keyvar before the union
Date: Wed, 4 Dec 2013 17:54:22 +0000	[thread overview]
Message-ID: <529F6C4E.30606@citrix.com> (raw)
In-Reply-To: <1386179336-2829-1-git-send-email-ian.campbell@citrix.com>

On 04/12/13 17:48, Ian Campbell wrote:
> This is Coverity CID 1135378 and 1135379.
>
> Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
> Cc: Andrew Cooper <andrew.cooper3@citrix.com>

This sound plausible, although given my unfamiliarity with gentest.py, I
dont feel as if a Reviewed-by tag is appropriate.

~Andrew

> ---
>  tools/libxl/gentest.py |    1 +
>  1 file changed, 1 insertion(+)
>
> diff --git a/tools/libxl/gentest.py b/tools/libxl/gentest.py
> index 6fab493..722b7f4 100644
> --- a/tools/libxl/gentest.py
> +++ b/tools/libxl/gentest.py
> @@ -42,6 +42,7 @@ def gen_rand_init(ty, v, indent = "    ", parent = None):
>      elif isinstance(ty, idl.KeyedUnion):
>          if parent is None:
>              raise Exception("KeyedUnion type must have a parent")
> +        s += gen_rand_init(ty.keyvar.type, parent + ty.keyvar.name, indent, parent)
>          s += "switch (%s) {\n" % (parent + ty.keyvar.name)
>          for f in ty.fields:
>              (nparent,fexpr) = ty.member(v, f, parent is None)

  reply	other threads:[~2013-12-04 17:54 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-12-04 17:28 New Coverity issues (tools/libxl/testidl.c) Andrew Cooper
2013-12-04 17:48 ` [PATCH] tools: libxl: testidl: initialise the KeyedUnion keyvar before the union Ian Campbell
2013-12-04 17:54   ` Andrew Cooper [this message]
2013-12-05 11:39     ` Ian Campbell
2013-12-10 14:12       ` Ian Jackson

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=529F6C4E.30606@citrix.com \
    --to=andrew.cooper3@citrix.com \
    --cc=ian.campbell@citrix.com \
    --cc=ian.jackson@eu.citrix.com \
    --cc=xen-devel@lists.xen.org \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.