]> git.ipfire.org Git - thirdparty/iw.git/blobdiff - offch.c
info: macro-ify ext_feat_print()
[thirdparty/iw.git] / offch.c
diff --git a/offch.c b/offch.c
index b40a52339deefe97b5ffd83356c2d43d12f2a198..19e170e906af5ec0d694caf8506950cd9983201f 100644 (file)
--- a/offch.c
+++ b/offch.c
@@ -9,11 +9,15 @@
 #include "nl80211.h"
 #include "iw.h"
 
-static int offchannel(struct nl80211_state *state, struct nl_cb *cb,
-                     struct nl_msg *msg, int argc, char **argv)
+static int offchannel(struct nl80211_state *state,
+                     struct nl_msg *msg, int argc, char **argv,
+                     enum id_input id)
 {
        char *end;
 
+       if (argc < 2)
+               return 1;
+
        /* freq */
        NLA_PUT_U32(msg, NL80211_ATTR_WIPHY_FREQ,
                    strtoul(argv[0], &end, 10));