diff options
author | Martin Wimpress <[email protected]> | 2015-06-09 22:39:55 +0100 |
---|---|---|
committer | Martin Wimpress <[email protected]> | 2015-06-09 22:39:55 +0100 |
commit | f4e47f6592311dc45e48a46e65dbb2ab5415727e (patch) | |
tree | f70d91003bd50276c4ed8065aa6bb4d0f6c4bbc0 /plugins/mpris/msd-mpris-manager.c | |
parent | 86c9bfbe92e236d1c2318096bb791af06a0806a7 (diff) | |
parent | 395263ea04514a37a93ff676001eb211149e4b52 (diff) | |
download | mate-settings-daemon-f4e47f6592311dc45e48a46e65dbb2ab5415727e.tar.bz2 mate-settings-daemon-f4e47f6592311dc45e48a46e65dbb2ab5415727e.tar.xz |
Merge pull request #104 from PoZitron/master
fix mpris plugin "vanish" function
Diffstat (limited to 'plugins/mpris/msd-mpris-manager.c')
-rw-r--r-- | plugins/mpris/msd-mpris-manager.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/plugins/mpris/msd-mpris-manager.c b/plugins/mpris/msd-mpris-manager.c index 1427044..96d9cff 100644 --- a/plugins/mpris/msd-mpris-manager.c +++ b/plugins/mpris/msd-mpris-manager.c @@ -134,6 +134,7 @@ mp_name_vanished (GDBusConnection *connection, MsdMprisManager *manager) { gchar *player_name; + GList *player_list; if (g_queue_is_empty (manager->priv->media_player_queue)) return; @@ -142,7 +143,11 @@ mp_name_vanished (GDBusConnection *connection, player_name = get_player_name(name); - g_queue_remove (manager->priv->media_player_queue, player_name); + player_list = g_queue_find_custom (manager->priv->media_player_queue, + player_name, g_strcmp0); + + if (player_list) + g_queue_remove (manager->priv->media_player_queue, player_list->data); g_free (player_name); } |