module_mpris: fixed a crash on startup

Non existing clients are now handled correctly.
This commit is contained in:
haruInDisguise 2025-03-20 00:16:58 +01:00
parent 4ed93d9b68
commit c1ddafd34a

View file

@ -733,7 +733,7 @@ find_existing_clients(struct context *context, sd_bus *connection, uint32_t time
sd_bus_message_close_container(list_names_message); sd_bus_message_close_container(list_names_message);
sd_bus_message_unref(list_names_message); sd_bus_message_unref(list_names_message);
return status > 0; return status > 0 && context->clients.length > 0;
} }
static bool static bool