Andrew Cooper writes ("Re: [Xen-devel] [PATCH for-4.10] libxl: handle NULL in
libxl__enum_from_string"):
> On 13/10/17 14:01, Ian Jackson wrote:
> > Instead, what we have actually done so far, is annotate when a pointer
> > parameter *may* be NULL, and, in t
On 13/10/17 14:01, Ian Jackson wrote:
> Wei Liu writes ("Re: [PATCH for-4.10] libxl: handle NULL in
> libxl__enum_from_string"):
>> I agree they shouldn't be called with NULL. We should guard against
>> error (here or the libxl_*_type_from_string) or annotate the input can't
>> be NULL.
> I mean,
Wei Liu writes ("Re: [PATCH for-4.10] libxl: handle NULL in
libxl__enum_from_string"):
> I agree they shouldn't be called with NULL. We should guard against
> error (here or the libxl_*_type_from_string) or annotate the input can't
> be NULL.
I mean, who calls any libxl_*_from_string with
On Fri, Oct 13, 2017 at 01:46:57PM +0100, Ian Jackson wrote:
> Wei Liu writes ("[PATCH for-4.10] libxl: handle NULL in
> libxl__enum_from_string"):
> > Discovered by Coverity.
>
> But. Surely it is very wrong
>
> > @@ -1017,7 +1017,7 @@ int libxl_get_max_nodes(libxl_ctx *ctx)
> > int
Wei Liu writes ("[PATCH for-4.10] libxl: handle NULL in
libxl__enum_from_string"):
> Discovered by Coverity.
But. Surely it is very wrong
> @@ -1017,7 +1017,7 @@ int libxl_get_max_nodes(libxl_ctx *ctx)
> int libxl__enum_from_string(const libxl_enum_string_table *t,
>
Discovered by Coverity.
Signed-off-by: Wei Liu
---
Cc: Ian Jackson
---
tools/libxl/libxl_utils.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/tools/libxl/libxl_utils.c b/tools/libxl/libxl_utils.c
index