All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH BlueZ] client: Invalidate scan filter on "scan" command
@ 2023-11-08 16:19 Jonas Dreßler
  2023-11-08 17:28 ` [BlueZ] " bluez.test.bot
  2023-11-13 19:22 ` [PATCH BlueZ] " patchwork-bot+bluetooth
  0 siblings, 2 replies; 3+ messages in thread
From: Jonas Dreßler @ 2023-11-08 16:19 UTC (permalink / raw)
  To: linux-bluetooth; +Cc: Jonas Dreßler

The "scan bredr" and "scan le" commands are broken right now because the
transport filter gets set, but not actually invalidated.

Invalidate the filter with `filter.set = false` so that it actually gets
updated when set_discovery_filter() is called afterwards.
---
 client/main.c | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

diff --git a/client/main.c b/client/main.c
index 88b5d5d0c..51d08a67a 100644
--- a/client/main.c
+++ b/client/main.c
@@ -1325,9 +1325,14 @@ static void cmd_scan(int argc, char *argv[])
 		return bt_shell_noninteractive_quit(EXIT_FAILURE);
 
 	if (enable == TRUE) {
-		if (strcmp(mode, "")) {
+		if (!g_strcmp0(mode, "")) {
+			g_free(filter.transport);
+			filter.transport = NULL;
+			filter.set = false;
+		} else {
 			g_free(filter.transport);
 			filter.transport = g_strdup(mode);
+			filter.set = false;
 		}
 
 		set_discovery_filter(false);
-- 
2.41.0


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

* RE: [BlueZ] client: Invalidate scan filter on "scan" command
  2023-11-08 16:19 [PATCH BlueZ] client: Invalidate scan filter on "scan" command Jonas Dreßler
@ 2023-11-08 17:28 ` bluez.test.bot
  2023-11-13 19:22 ` [PATCH BlueZ] " patchwork-bot+bluetooth
  1 sibling, 0 replies; 3+ messages in thread
From: bluez.test.bot @ 2023-11-08 17:28 UTC (permalink / raw)
  To: linux-bluetooth, verdre

[-- Attachment #1: Type: text/plain, Size: 945 bytes --]

This is automated email and please do not reply to this email!

Dear submitter,

Thank you for submitting the patches to the linux bluetooth mailing list.
This is a CI test results with your patch series:
PW Link:https://patchwork.kernel.org/project/bluetooth/list/?series=799718

---Test result---

Test Summary:
CheckPatch                    PASS      0.64 seconds
GitLint                       PASS      0.30 seconds
BuildEll                      PASS      24.31 seconds
BluezMake                     PASS      562.65 seconds
MakeCheck                     PASS      10.60 seconds
MakeDistcheck                 PASS      149.28 seconds
CheckValgrind                 PASS      208.63 seconds
CheckSmatch                   PASS      312.79 seconds
bluezmakeextell               PASS      95.60 seconds
IncrementalBuild              PASS      509.70 seconds
ScanBuild                     PASS      922.37 seconds



---
Regards,
Linux Bluetooth


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

* Re: [PATCH BlueZ] client: Invalidate scan filter on "scan" command
  2023-11-08 16:19 [PATCH BlueZ] client: Invalidate scan filter on "scan" command Jonas Dreßler
  2023-11-08 17:28 ` [BlueZ] " bluez.test.bot
@ 2023-11-13 19:22 ` patchwork-bot+bluetooth
  1 sibling, 0 replies; 3+ messages in thread
From: patchwork-bot+bluetooth @ 2023-11-13 19:22 UTC (permalink / raw)
  To: =?utf-8?q?Jonas_Dre=C3=9Fler_=3Cverdre=40v0yd=2Enl=3E?=; +Cc: linux-bluetooth

Hello:

This patch was applied to bluetooth/bluez.git (master)
by Luiz Augusto von Dentz <luiz.von.dentz@intel.com>:

On Wed,  8 Nov 2023 17:19:49 +0100 you wrote:
> The "scan bredr" and "scan le" commands are broken right now because the
> transport filter gets set, but not actually invalidated.
> 
> Invalidate the filter with `filter.set = false` so that it actually gets
> updated when set_discovery_filter() is called afterwards.
> ---
>  client/main.c | 7 ++++++-
>  1 file changed, 6 insertions(+), 1 deletion(-)

Here is the summary with links:
  - [BlueZ] client: Invalidate scan filter on "scan" command
    https://git.kernel.org/pub/scm/bluetooth/bluez.git/?id=7ef40617a049

You are awesome, thank you!
-- 
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html



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

end of thread, other threads:[~2023-11-13 19:22 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-11-08 16:19 [PATCH BlueZ] client: Invalidate scan filter on "scan" command Jonas Dreßler
2023-11-08 17:28 ` [BlueZ] " bluez.test.bot
2023-11-13 19:22 ` [PATCH BlueZ] " patchwork-bot+bluetooth

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.