From 865ca48af9401427b4ddb6454f1db27b0652f381 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pali=20Roh=C3=A1r?= Date: Fri, 12 Jun 2020 15:34:37 +0200 Subject: [PATCH] fixup! bluetooth: Change codec API for choosing remote endpoint --- src/modules/bluetooth/a2dp-codec-sbc.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/modules/bluetooth/a2dp-codec-sbc.c b/src/modules/bluetooth/a2dp-codec-sbc.c index f275586ef..3c03ee8e4 100644 --- a/src/modules/bluetooth/a2dp-codec-sbc.c +++ b/src/modules/bluetooth/a2dp-codec-sbc.c @@ -232,9 +232,9 @@ static int cmp_endpoints_by_freq(const a2dp_sbc_t *capabilities1, const a2dp_sbc if (freq1 > freq2) return 1; } else if (freq1) { - return freq1; + return -1; } else if (freq2) { - return freq2; + return 1; } else { for (i = PA_ELEMENTSOF(freq_table)-1; i >= 0; i--) { if (capabilities1->frequency & freq_table[i].cap) -- GitLab