eiwd

no dbus iwd with iwctl functionality
git clone https://git.daat.foo/repos/eiwd.git
Log | Files | Refs | Submodules | README | LICENSE

commit 1c5a2da046198828b64242383acaa135735de5ca
parent 778dacd2622a6c0e5e0d26c1dc964170062d921c
Author: James Prestwood <prestwoj@gmail.com>
Date:   Thu,  3 Mar 2022 12:09:55 -0800

knownnetworks: use band_freq_to_channel to verify known freqs

With the addition of 6GHz '6000' is no longer the maximum frequency
that could be in .known_network.freq. For more robustness
band_freq_to_channel is used to validate the frequency.

Diffstat:
Msrc/knownnetworks.c | 4+++-
1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/src/knownnetworks.c b/src/knownnetworks.c @@ -45,6 +45,7 @@ #include "src/scan.h" #include "src/util.h" #include "src/watchlist.h" +#include "src/band.h" static struct l_queue *known_networks; static size_t num_known_hidden_networks; @@ -856,7 +857,8 @@ static struct l_queue *known_frequencies_from_string(char *freq_set_str) t = strtoul(freq_set_str, &freq_set_str, 10); - if (unlikely(errno == ERANGE || !t || t > 6000)) + if (unlikely(errno == ERANGE || !t || + !band_freq_to_channel(t, NULL))) goto error; known_freq = l_new(struct known_frequency, 1);