]> git.ipfire.org Git - thirdparty/iw.git/blobdiff - cqm.c
iw: display 5/10 MHz channel widths
[thirdparty/iw.git] / cqm.c
diff --git a/cqm.c b/cqm.c
index 3da2b5465cce0d4e352f608f790fde4661336bc7..093b744baba501c3bba645720eca1a826462d4b9 100644 (file)
--- a/cqm.c
+++ b/cqm.c
@@ -9,8 +9,9 @@
 #include "nl80211.h"
 #include "iw.h"
 
-static int iw_cqm_rssi(struct nl80211_state *state, struct nl_cb *cb,
-                      struct nl_msg *msg, int argc, char **argv)
+static int iw_cqm_rssi(struct nl80211_state *state,
+                      struct nl_msg *msg, int argc, char **argv,
+                      enum id_input id)
 {
        struct nl_msg *cqm = NULL;
        int thold = 0;
@@ -33,6 +34,8 @@ static int iw_cqm_rssi(struct nl80211_state *state, struct nl_cb *cb,
 
        /* connection quality monitor attributes */
        cqm = nlmsg_alloc();
+       if (!cqm)
+               return -ENOMEM;
 
        NLA_PUT_U32(cqm, NL80211_ATTR_CQM_RSSI_THOLD, thold);
        NLA_PUT_U32(cqm, NL80211_ATTR_CQM_RSSI_HYST, hyst);