]> git.ipfire.org Git - thirdparty/hostap.git/commitdiff
nl80211: Fix compatibility with older version of libnl
authorIlan Peer <ilan.peer@intel.com>
Wed, 1 Oct 2014 06:01:25 +0000 (08:01 +0200)
committerJouni Malinen <j@w1.fi>
Fri, 3 Oct 2014 08:34:51 +0000 (11:34 +0300)
Commit 97ed9a06df566357f0ebe57f8080f78726e78db6 ('nl80211: Remove bridge
FDB entry upon sta_remove()') used nl_sock and nl_socket_* functions
which are not compatible with older versions of libnl. Fix this.

Signed-off-by: Ilan Peer <ilan.peer@intel.com>
src/drivers/driver_nl80211.c

index 5c922a0576f654df812643a463ac55d3bd024b5b..026cb7d462938d82aff130f030d044ba4bf37d99 100644 (file)
@@ -331,7 +331,7 @@ struct wpa_driver_nl80211_data {
 
        int eapol_sock; /* socket for EAPOL frames */
 
-       struct nl_sock *rtnl_sk; /* nl_sock for NETLINK_ROUTE */
+       struct nl_handle *rtnl_sk; /* nl_sock for NETLINK_ROUTE */
 
        int default_if_indices[16];
        int *if_indices;
@@ -4938,7 +4938,7 @@ static void wpa_driver_nl80211_deinit(struct i802_bss *bss)
                                   "interface %s from bridge %s: %s",
                                   bss->ifname, bss->brname, strerror(errno));
                if (drv->rtnl_sk)
-                       nl_socket_free(drv->rtnl_sk);
+                       nl80211_handle_destroy(drv->rtnl_sk);
        }
        if (bss->added_bridge) {
                if (linux_br_del(drv->global->ioctl_sock, bss->brname) < 0)