wiphy: Fix memory leak

Whenever we find an existing BSS, we should free the old object since it
is being removed from the old_bss_list via l_queue_remove_if
This commit is contained in:
Denis Kenzior 2014-11-07 22:35:07 -06:00
parent 333b28bf3a
commit ad86c91b38
1 changed files with 2 additions and 0 deletions

View File

@ -641,6 +641,8 @@ static void parse_bss(struct netdev *netdev, struct l_genl_attr *attr)
bss_address_to_string(bss));
if (network)
network->bss = bss;
bss_free(old_bss);
}
l_queue_push_head(netdev->bss_list, bss);