mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2025-02-01 17:35:17 +00:00
util: Avoid Coverity FORWARD_NULL
Coverity claims it could be possible to call virDBusTypeStackFree with *stack == NULL and although the two API's that call it don't appear to allow that - I suppose it's better to be safe than sorry
This commit is contained in:
parent
53caf99db6
commit
c78e1cfcb5
@ -544,6 +544,10 @@ static void virDBusTypeStackFree(virDBusTypeStack **stack,
|
||||
size_t *nstack)
|
||||
{
|
||||
size_t i;
|
||||
|
||||
if (!*stack)
|
||||
return;
|
||||
|
||||
/* The iter in the first level of the stack is the
|
||||
* root iter which must not be freed
|
||||
*/
|
||||
|
Loading…
x
Reference in New Issue
Block a user