linux-bluetooth.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v2] mpris-proxy: add --target to target a specific player
@ 2024-01-06 22:15 Willow Barraco
  2024-01-06 23:29 ` [v2] " bluez.test.bot
  0 siblings, 1 reply; 2+ messages in thread
From: Willow Barraco @ 2024-01-06 22:15 UTC (permalink / raw)
  To: linux-bluetooth

Signed-off-by: Willow Barraco <contact@willowbarraco.fr>
---
v2: Fix CI warning
 tools/mpris-proxy.c | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/tools/mpris-proxy.c b/tools/mpris-proxy.c
index e5fc91fdb..dc328031b 100644
--- a/tools/mpris-proxy.c
+++ b/tools/mpris-proxy.c
@@ -53,6 +53,7 @@ static GSList *transports = NULL;
 
 static gboolean option_version = FALSE;
 static gboolean option_export = FALSE;
+static gchar *option_target = "";
 
 struct tracklist {
 	GDBusProxy *proxy;
@@ -428,6 +429,11 @@ static void add_player(DBusConnection *conn, const char *name,
 	if (!adapter)
 		return;
 
+	if (strcmp(option_target, "") && strcmp(name, option_target)) {
+		printf("Not the target player, skipped\n");
+		return;
+	}
+
 	player = find_player_by_bus_name(name);
 	if (player == NULL) {
 		reply = get_all(conn, name);
@@ -733,6 +739,8 @@ static GOptionEntry options[] = {
 				"Show version information and exit" },
 	{ "export", 'e', 0, G_OPTION_ARG_NONE, &option_export,
 				"Export remote players" },
+	{ "target", 't', 0, G_OPTION_ARG_STRING, &option_target,
+				"Target a specific player" },
 	{ NULL },
 };
 
-- 
2.43.0


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

* RE: [v2] mpris-proxy: add --target to target a specific player
  2024-01-06 22:15 [PATCH v2] mpris-proxy: add --target to target a specific player Willow Barraco
@ 2024-01-06 23:29 ` bluez.test.bot
  0 siblings, 0 replies; 2+ messages in thread
From: bluez.test.bot @ 2024-01-06 23:29 UTC (permalink / raw)
  To: linux-bluetooth, contact

[-- Attachment #1: Type: text/plain, Size: 946 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=814873

---Test result---

Test Summary:
CheckPatch                    PASS      0.32 seconds
GitLint                       PASS      0.21 seconds
BuildEll                      PASS      23.60 seconds
BluezMake                     PASS      706.83 seconds
MakeCheck                     PASS      12.02 seconds
MakeDistcheck                 PASS      157.79 seconds
CheckValgrind                 PASS      220.22 seconds
CheckSmatch                   PASS      323.93 seconds
bluezmakeextell               PASS      105.13 seconds
IncrementalBuild              PASS      667.43 seconds
ScanBuild                     PASS      918.76 seconds



---
Regards,
Linux Bluetooth


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

end of thread, other threads:[~2024-01-06 23:29 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-01-06 22:15 [PATCH v2] mpris-proxy: add --target to target a specific player Willow Barraco
2024-01-06 23:29 ` [v2] " bluez.test.bot

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).