3
0
mirror of https://git.kernel.org/pub/scm/network/wireless/iwd.git synced 2024-11-29 22:19:23 +01:00

ap: Add missing ap_config_free() in error path

This commit is contained in:
Andrew Zaborowski 2021-03-05 16:09:28 +01:00 committed by Denis Kenzior
parent fe6f4153c5
commit 3621e998c9

View File

@ -3119,8 +3119,10 @@ static struct l_dbus_message *ap_dbus_start_profile(struct l_dbus *dbus,
config->profile = storage_get_path("ap/%s.ap", ssid); config->profile = storage_get_path("ap/%s.ap", ssid);
ap_if->ap = ap_start(ap_if->netdev, config, &ap_dbus_ops, &err, ap_if); ap_if->ap = ap_start(ap_if->netdev, config, &ap_dbus_ops, &err, ap_if);
if (!ap_if->ap) if (!ap_if->ap) {
ap_config_free(config);
return dbus_error_from_errno(err, message); return dbus_error_from_errno(err, message);
}
ap_if->pending = l_dbus_message_ref(message); ap_if->pending = l_dbus_message_ref(message);
return NULL; return NULL;