dcb: Plug a leaking DCB socket buffer

DCB socket buffer is allocated in dcb_init(), but never freed(). Free it
in dcb_fini().

Fixes: 67033d1c1c ("Add skeleton of a new tool, dcb")
Signed-off-by: Petr Machata <me@pmachata.org>
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
This commit is contained in:
Petr Machata 2021-01-03 11:57:23 +01:00 committed by Stephen Hemminger
parent 2e99c28161
commit b4c0cad06e

View File

@ -38,6 +38,7 @@ static void dcb_fini(struct dcb *dcb)
{
delete_json_obj_plain();
mnl_socket_close(dcb->nl);
free(dcb->buf);
}
static struct dcb *dcb_alloc(void)