When ubus_add_object fails, the ubus_connect object is not freed, so the connection leaks. Add ubus_destroy to free the connection object.
Signed-off-by: Oldřich Jedlička <oldium....@gmail.com> --- src/ubus.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/ubus.c b/src/ubus.c index 79e2563..c7f6b19 100644 --- a/src/ubus.c +++ b/src/ubus.c @@ -102,6 +102,7 @@ void ubus_init() my_syslog(LOG_ERR, _("Cannot add object to UBus: %s"), ubus_strerror(ret)); error_logged = 1; } + ubus_destroy(ubus); return; } -- 2.17.1 _______________________________________________ Dnsmasq-discuss mailing list Dnsmasq-discuss@lists.thekelleys.org.uk http://lists.thekelleys.org.uk/mailman/listinfo/dnsmasq-discuss