diff mbox

wpa_supplicant: typo in wpa_scan_result_compar() causes wrong scan results sorting (and wrong roaming decision)

Message ID EC18CD4F248FCC49B53632D772F729D62638FEF9@DFRE01.ent.ti.com
State Changes Requested
Headers show

Commit Message

Hahn, Maital July 8, 2015, 11:26 a.m. UTC

Comments

Jouni Malinen July 8, 2015, 12:36 p.m. UTC | #1
On Wed, Jul 08, 2015 at 11:26:53AM +0000, Hahn, Maital wrote:
> diff --git a/wpa_supplicant/scan.c b/wpa_supplicant/scan.c
> --- a/wpa_supplicant/scan.c
> +++ b/wpa_supplicant/scan.c
> @@ -1717,7 +1717,7 @@ static int wpa_scan_result_compar(const void *a, const void *b)

Could you please read the top level CONTRIBUTIONS file and send this
with a Signed-off-by: line in the commit message as described in that
file so that I can apply the changes?
diff mbox

Patch

diff --git a/wpa_supplicant/scan.c b/wpa_supplicant/scan.c
--- a/wpa_supplicant/scan.c
+++ b/wpa_supplicant/scan.c
@@ -1717,7 +1717,7 @@  static int wpa_scan_result_compar(const void *a, const void *b)
                snr_a_full = wa->snr;
                snr_a = MIN(wa->snr, GREAT_SNR);
                snr_b_full = wb->snr;
-               snr_b = MIN(wa->snr, GREAT_SNR);
+               snr_b = MIN(wb->snr, GREAT_SNR);
        } else {
                /* Level is not in dBm, so we can't calculate
                 * SNR. Just use raw level (units unknown). */