clang-analyzer complains that "ret" may be returned uninitialized
which can't happen with a valid session configuration. For this to
occur, either libxml2 would have to return a bogus ChildElementCount
(return non-zero when there a actually no child nodes) _or_ the node
would have children of an unexpected type, which would be catched by
the validation performed against the XSD.
Nonetheless, the value is initialized here to silence this warning.
Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
int process_pid_tracker_node(xmlNodePtr pid_tracker_node,
struct lttng_handle *handle)
{
- int ret, child;
+ int ret = 0, child;
xmlNodePtr targets_node = NULL;
xmlNodePtr node;