All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH BlueZ] client: Fix advertise broadcast
@ 2021-05-14 23:58 Luiz Augusto von Dentz
  2021-05-15  1:40 ` [BlueZ] " bluez.test.bot
  0 siblings, 1 reply; 3+ messages in thread
From: Luiz Augusto von Dentz @ 2021-05-14 23:58 UTC (permalink / raw)
  To: linux-bluetooth

From: Luiz Augusto von Dentz <luiz.von.dentz@intel.com>

When advertising with type broadcast it cannot be discoverable as that
would require setting flags which is not allowed by the spec.
---
 client/advertising.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/client/advertising.c b/client/advertising.c
index 3bf12fe87..e40086c98 100644
--- a/client/advertising.c
+++ b/client/advertising.c
@@ -512,6 +512,9 @@ void ad_register(DBusConnection *conn, GDBusProxy *manager, const char *type)
 	g_free(ad.type);
 	ad.type = g_strdup(type);
 
+	if (!strcasecmp(ad.type, "Broadcast"))
+		ad.discoverable = false;
+
 	if (g_dbus_register_interface(conn, AD_PATH, AD_IFACE, ad_methods,
 					NULL, ad_props, NULL, NULL) == FALSE) {
 		bt_shell_printf("Failed to register advertising object\n");
-- 
2.30.2


^ permalink raw reply related	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2021-05-17 21:54 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-05-14 23:58 [PATCH BlueZ] client: Fix advertise broadcast Luiz Augusto von Dentz
2021-05-15  1:40 ` [BlueZ] " bluez.test.bot
2021-05-17 21:53   ` Luiz Augusto von Dentz

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.