From 34896b0205c0030b7da53101bbc45ed50c25f158 Mon Sep 17 00:00:00 2001 From: wAABBsif Date: Wed, 21 Jan 2026 00:17:57 -0500 Subject: [PATCH] Handle when PlaybackStatus doesn't return variant --- UnleashedRecomp/os/linux/media_linux.cpp | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/UnleashedRecomp/os/linux/media_linux.cpp b/UnleashedRecomp/os/linux/media_linux.cpp index fc40e687..98f2fdf8 100644 --- a/UnleashedRecomp/os/linux/media_linux.cpp +++ b/UnleashedRecomp/os/linux/media_linux.cpp @@ -151,10 +151,13 @@ static bool IsMediaPlayerPlaying(DBusConnection* connection, const std::string& return false; } - if (dbus_message_iter_get_arg_type(&rootIterator) != DBUS_TYPE_VARIANT) + if (dbus_message_iter_get_arg_type(&rootIterator) == DBUS_TYPE_VARIANT) { - LOG_ERROR("D-Bus message returned invalid type!"); - return false; + dbus_message_iter_recurse(&rootIterator, &arrayIterator); + } + else + { + arrayIterator = rootIterator; } dbus_message_iter_recurse(&rootIterator, &arrayIterator);