diff mbox series

[BlueZ,v1,2/2] adapter: Create devices if they are connectable

Message ID 20240814185714.844117-2-luiz.dentz@gmail.com
State New
Headers show
Series [BlueZ,v1,1/2] device: Promote Device.{AdvertisingData, AdvertisingFlags} to stable | expand

Commit Message

Luiz Augusto von Dentz Aug. 14, 2024, 6:57 p.m. UTC
From: Luiz Augusto von Dentz <luiz.von.dentz@intel.com>

Rather than just depend on discoverable also check if the device is
considered connectable since upper layers shall now be able to use
AdvertisingFlags to detect when a device shall be considered visible
or not and bluetoothctl has been using it since commit 815f779aa8e4
("client: Use AdvertisingFlags when available").
---
 src/adapter.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff mbox series

Patch

diff --git a/src/adapter.c b/src/adapter.c
index 85ddfc16568f..245de4456868 100644
--- a/src/adapter.c
+++ b/src/adapter.c
@@ -7293,7 +7293,7 @@  void btd_adapter_device_found(struct btd_adapter *adapter,
 				MGMT_SETTING_ISO_SYNC_RECEIVER))
 			monitoring = true;
 
-		if (!discoverable && !monitoring && !eir_data.rsi) {
+		if (!discoverable && !monitoring && not_connectable) {
 			eir_data_free(&eir_data);
 			return;
 		}