Files
xen/tools/libs
Roger Pau Monne 98cdab1679 tools/{lib,}xl: fix usage of error return from json_tokener_parse_verbose()
It's possible for json_tokener_parse_verbose() to return NULL and leave the
error parameter unset.  Initialize the error variable at definition to an
existing error token to make sure it's not uninitialized in case of
failure.

Reported by XenServer internal Coverity instance.

Fixes: 7e95dab9eb ("libxl: Convert libxl__json_parse() to use json-c")
Fixes: f6c6f2679d ("libxl: Convert libxl__object_to_json() to json-c")
Signed-off-by: Roger Pau Monné <roger.pau@citrix.com>
Reviewed-by: Andrew Cooper <andrew.cooper3@citrix.com>
Release-Acked-by: Oleksii Kurochko <oleksii.kurochko@gmail.com>
2025-10-16 17:20:10 +02:00
..
2025-04-08 09:39:50 +02:00