mem leaks in netconf hello

This commit is contained in:
Olof hagsand 2021-03-13 17:50:43 +01:00
parent 9087694b58
commit 1f5e71512a
2 changed files with 6 additions and 2 deletions

View file

@ -130,9 +130,9 @@ netconf_hello_msg(clicon_handle h,
int retval = -1;
cvec *nsc = NULL; // namespace context
cxobj **vec = NULL;
size_t veclen;
cxobj *x;
cxobj *xcap;
size_t veclen;
int foundbase;
char *body;
@ -169,6 +169,8 @@ netconf_hello_msg(clicon_handle h,
}
retval = 0;
done:
if (vec)
free(vec);
return retval;
}