From b7a7bc7db2b88bcf0be2bb4ae64f2fce68738116 Mon Sep 17 00:00:00 2001 From: haruInDisguise Date: Thu, 20 Mar 2025 16:40:33 +0100 Subject: [PATCH] module_mpris: Removed incorrect/redundant include --- modules/mpris.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/modules/mpris.c b/modules/mpris.c index b238093..ecac04b 100644 --- a/modules/mpris.c +++ b/modules/mpris.c @@ -23,7 +23,6 @@ #include "../plugin.h" #include "dbus.h" -#include "yml.h" #define is_empty_string(str) ((str) == NULL || (str)[0] == '\0') @@ -1070,10 +1069,12 @@ run(struct module *mod) break; } + mtx_lock(&mod->lock); if (!context_process_events(context, m->timeout_ms)) { aborted = true; break; } + mtx_unlock(&mod->lock); /* Process dynamic updates, received through the contexts * monitor connection. The 'upate_message' attribute is set @@ -1083,9 +1084,11 @@ run(struct module *mod) assert(context->current_client != NULL); assert(context->update_message != NULL); + mtx_lock(&mod->lock); context->has_update = false; aborted = !update_client_from_message(context->current_client, context->update_message); context->update_message = sd_bus_message_unref(context->update_message); + mtx_unlock(&mod->lock); } bar->refresh(bar);