service = __connman_service_lookup_from_network(dhcp->network);
if (service == NULL)
- return;
+ goto out;
ipconfig = __connman_service_get_ip4config(service);
if (ipconfig == NULL)
- return;
+ goto out;
__connman_6to4_remove(ipconfig);
if (dhcp->callback != NULL && callback)
dhcp->callback(dhcp->network, FALSE);
+out:
dhcp_free(dhcp);
}
__connman_service_nameserver_append(service,
dhcp->nameservers[i]);
}
+ } else {
+ g_strfreev(nameservers);
}
if (g_strcmp0(timeserver, dhcp->timeserver) != 0) {