Message ID | 20231220131509.267549-1-prestwoj@gmail.com (mailing list archive) |
---|---|
State | New |
Headers | show |
Series | knownnetworks: limit 5 recent frequencies per network | expand |
Context | Check | Description |
---|---|---|
tedd_an/pre-ci_am | success | Success |
prestwoj/iwd-alpine-ci-fetch | success | Fetch PR |
prestwoj/iwd-ci-gitlint | success | GitLint |
prestwoj/iwd-ci-fetch | success | Fetch PR |
prestwoj/iwd-alpine-ci-makedistcheck | success | Make Distcheck |
prestwoj/iwd-alpine-ci-incremental_build | success | Incremental build not run PASS |
prestwoj/iwd-ci-makedistcheck | success | Make Distcheck |
prestwoj/iwd-ci-incremental_build | success | Incremental build not run PASS |
prestwoj/iwd-alpine-ci-build | success | Build - Configure |
prestwoj/iwd-ci-build | success | Build - Configure |
prestwoj/iwd-ci-makecheck | success | Make Check |
prestwoj/iwd-ci-makecheckvalgrind | success | Make Check w/Valgrind |
prestwoj/iwd-ci-clang | success | clang PASS |
prestwoj/iwd-alpine-ci-makecheckvalgrind | success | Make Check w/Valgrind |
prestwoj/iwd-alpine-ci-makecheck | success | Make Check |
prestwoj/iwd-ci-testrunner | success | test-runner PASS |
diff --git a/src/knownnetworks.c b/src/knownnetworks.c index e44109fd..ecdd79a1 100644 --- a/src/knownnetworks.c +++ b/src/knownnetworks.c @@ -540,10 +540,12 @@ struct scan_freq_set *known_networks_get_recent_frequencies( network_entry = network_entry->next, num_networks_tosearch--) { const struct network_info *network = network_entry->data; + uint8_t num_freqs = 5; for (freq_entry = l_queue_get_entries( network->known_frequencies); - freq_entry; freq_entry = freq_entry->next) { + freq_entry && num_freqs; + freq_entry = freq_entry->next, num_freqs--) { const struct known_frequency *known_freq = freq_entry->data;