Running test "ovn-controller-vtep binding 2" with address sanitizer enabled resulted in a failure due to a memory leak. The cached switch port's bindings were not being freed when the port was freed. The fix is to destroy the bindings hash table when the switch port is freed.
Signed-off-by: Mark Michelson <[email protected]> Reported-by: Lance Richardson <[email protected]> --- vtep/vtep-ctl.c | 1 + 1 file changed, 1 insertion(+) diff --git a/vtep/vtep-ctl.c b/vtep/vtep-ctl.c index bbdf57fad..17afa0c59 100644 --- a/vtep/vtep-ctl.c +++ b/vtep/vtep-ctl.c @@ -542,6 +542,7 @@ del_cached_port(struct vtep_ctl_context *vtepctl_ctx, ovs_list_remove(&port->ports_node); shash_find_and_delete(&vtepctl_ctx->ports, cache_name); vteprec_physical_port_delete(port->port_cfg); + shash_destroy(&port->bindings); free(cache_name); free(port); } -- 2.13.3 _______________________________________________ dev mailing list [email protected] https://mail.openvswitch.org/mailman/listinfo/ovs-dev
