fix eval probe metric

This commit is contained in:
PolynomialDivision 2017-11-20 19:54:28 +01:00
parent d33a746e83
commit 6eee1214a2
2 changed files with 3 additions and 3 deletions

View file

@ -71,9 +71,9 @@ int eval_probe_metric(struct probe_entry_s probe_entry) {
// check if ap entry is available
if (mac_is_equal(ap_entry.bssid_addr, probe_entry.bssid_addr)) {
score += probe_entry.ht_support ? dawn_metric.ht_support : 0;
score += probe_entry.ht_support && ap_entry.ht ? dawn_metric.ht_support : 0;
score += !probe_entry.ht_support && !ap_entry.ht ? dawn_metric.no_ht_support : 0;
score += probe_entry.vht_support ? dawn_metric.vht_support : 0;
score += probe_entry.vht_support && ap_entry.vht ? dawn_metric.vht_support : 0;
score += !probe_entry.vht_support && !ap_entry.vht ? dawn_metric.no_vht_support : 0;
score += ap_entry.channel_utilization <= dawn_metric.max_chan_util ? dawn_metric.chan_util : 0;
}

View file

@ -377,7 +377,7 @@ static int add_subscriber(char *name) {
fprintf(stderr, "Failed to look up test object for %s\n", name);
return -1;
}
if(hostapd_array_check_id(id))
{
return 0;