Fix a potential double-free when we hit a non-"argument" node, which could
cause a 'goto err_out' with value still set to the one that was already
freed last time round the loop.
Cosmetic changes to the args array, and change the loop over them. The
'continue' on !arg->opt doesn't seem to be useful; let's use !arg->opt
as the condition to terminate the loop instead.
Most 'const' removal, although actually I think it probably *can* be
const if we just use xml_node->content directly, and that means we don't
need to free it at all. Didn't want to make that change without testing
it though.
Steal cookie->data instead of strdup() and then immediately freeing it,
like we do for Juniper.
Other trivial cosmetic changes (spaces, !x instead of x==NULL or even
X == NULL).
Signed-off-by: David Woodhouse <dwmw2@infradead.org>