From: Ben Greear <greearb@xxxxxxxxxxxxxxx> This allows one to configure exactly one rate for drivers such as ath10k that will only allow a single rate to be configured. Signed-off-by: Ben Greear <greearb@xxxxxxxxxxxxxxx> --- bitrate.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/bitrate.c b/bitrate.c index 4df6185..21217bf 100644 --- a/bitrate.c +++ b/bitrate.c @@ -176,6 +176,8 @@ static int handle_bitrates(struct nl80211_state *state, tmpd = strtod(argv[i], &end); if (*end != '\0') return 1; + if (tmpd == -1) /* terminator, could be empty list */ + break; if (tmpd < 1 || tmpd > 255 * 2) return 1; legacy[(*n_legacy)++] = tmpd * 2; @@ -184,6 +186,8 @@ static int handle_bitrates(struct nl80211_state *state, tmpl = strtol(argv[i], &end, 0); if (*end != '\0') return 1; + if (tmpl == -1) /* terminator, could be empty list */ + break; if (tmpl < 0 || tmpl > 255) return 1; mcs[(*n_mcs)++] = tmpl; -- 1.9.3 -- To unsubscribe from this list: send the line "unsubscribe linux-wireless" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html