mirror of
https://gitlab.freedesktop.org/pipewire/pipewire.git
synced 2025-12-14 08:56:37 -05:00
bluez5: fix msbc connect probe again
There's a report that on Intel 8086:2723 + Sony WH-1000XM4, the connect probe shuts the device down. So, use an invalid dst address instead, since we don't need the host to be up. Fixes:84bc0490a5Fixes:717004334b
This commit is contained in:
parent
75d76172fa
commit
ff8c3d208e
1 changed files with 3 additions and 5 deletions
|
|
@ -586,21 +586,19 @@ static bool device_supports_required_mSBC_transport_modes(
|
||||||
} else {
|
} else {
|
||||||
struct sockaddr_sco addr;
|
struct sockaddr_sco addr;
|
||||||
socklen_t len;
|
socklen_t len;
|
||||||
bdaddr_t dst;
|
|
||||||
int res;
|
int res;
|
||||||
|
|
||||||
/* Connect to device */
|
/* Connect to non-existent address */
|
||||||
str2ba(device->address, &dst);
|
|
||||||
len = sizeof(addr);
|
len = sizeof(addr);
|
||||||
memset(&addr, 0, len);
|
memset(&addr, 0, len);
|
||||||
addr.sco_family = AF_BLUETOOTH;
|
addr.sco_family = AF_BLUETOOTH;
|
||||||
bacpy(&addr.sco_bdaddr, &dst);
|
bacpy(&addr.sco_bdaddr, BDADDR_LOCAL);
|
||||||
|
|
||||||
spa_log_debug(backend->log, "connect to determine adapter msbc support...");
|
spa_log_debug(backend->log, "connect to determine adapter msbc support...");
|
||||||
|
|
||||||
/* Linux kernel code checks for features needed for BT_VOICE_TRANSPARENT
|
/* Linux kernel code checks for features needed for BT_VOICE_TRANSPARENT
|
||||||
* among the first checks it does, and fails with EOPNOTSUPP if not
|
* among the first checks it does, and fails with EOPNOTSUPP if not
|
||||||
* supported. The connection to self generally timeouts, so set it
|
* supported. The connection to generally timeouts, so set it
|
||||||
* nonblocking since we are just checking.
|
* nonblocking since we are just checking.
|
||||||
*/
|
*/
|
||||||
fcntl(sock, F_SETFL, O_NONBLOCK);
|
fcntl(sock, F_SETFL, O_NONBLOCK);
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue