diff options
author | Jörg Mayer <jmayer@loplof.de> | 2012-06-24 19:36:20 +0000 |
---|---|---|
committer | Jörg Mayer <jmayer@loplof.de> | 2012-06-24 19:36:20 +0000 |
commit | 2a2ddb7bcbfc164b82224b5fd9a0dd6513d10422 (patch) | |
tree | 6e6abca08f8452b58e045c9648a6d2ffcaa265f6 /ws80211_utils.c | |
parent | f7e438945f531db668642ca75f268c65b96a5679 (diff) |
Pontus Fuchs (via bug 6973):
Add libnl version 1 support for wireless toolbar.
svn path=/trunk/; revision=43462
Diffstat (limited to 'ws80211_utils.c')
-rw-r--r-- | ws80211_utils.c | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/ws80211_utils.c b/ws80211_utils.c index 6c100d4b98..3c7ea73d66 100644 --- a/ws80211_utils.c +++ b/ws80211_utils.c @@ -47,6 +47,20 @@ OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. #include <netlink/msg.h> #include <netlink/attr.h> +/* libnl 1.x compatibility code */ +#ifdef HAVE_LIBNL1 +#define nl_sock nl_handle +static inline struct nl_handle *nl_socket_alloc(void) +{ + return nl_handle_alloc(); +} + +static inline void nl_socket_free(struct nl_sock *h) +{ + nl_handle_destroy(h); +} +#endif /* HAVE_LIBNL1 */ + struct nl80211_state { struct nl_sock *nl_sock; int nl80211_id; |