From 050a29b3303955a477ea6b3ae79182a41f1d7d2d Mon Sep 17 00:00:00 2001 From: Luiz Augusto von Dentz Date: Mon, 17 Jun 2013 14:23:04 +0300 Subject: [PATCH] tools/mpris-player: Fix crash when forwarding player message The iterator to which the message should be copied to should be the copy message not the original message. --- tools/mpris-player.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tools/mpris-player.c b/tools/mpris-player.c index 099ae48f0..f17b5891a 100644 --- a/tools/mpris-player.c +++ b/tools/mpris-player.c @@ -361,7 +361,7 @@ static void copy_reply(DBusPendingCall *call, void *user_data) return; } - dbus_message_iter_init_append(msg, &iter); + dbus_message_iter_init_append(copy, &iter); if (!dbus_message_iter_init(reply, &args)) goto done; @@ -392,7 +392,7 @@ static DBusHandlerResult player_message(DBusConnection *conn, if (copy == NULL) return DBUS_HANDLER_RESULT_NOT_YET_HANDLED; - dbus_message_iter_init_append(msg, &iter); + dbus_message_iter_init_append(copy, &iter); append_iter(&iter, &args); if (!dbus_connection_send_with_reply(session, copy, &call, -1)) -- 2.47.3