From a56d5bdb53cc0f0a7c2a6bb91ca3240054e43db2 Mon Sep 17 00:00:00 2001 From: wm4 Date: Sat, 7 Mar 2020 12:39:03 +0100 Subject: [PATCH] client API: always reset new_property_events fields This was not reset in the num_properties==0 case. This didn't really matter, but for debugging it's slightly nicer to see new_property_events reset once the client thread is done with it. --- player/client.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/player/client.c b/player/client.c index 460632805f..91c86f4a88 100644 --- a/player/client.c +++ b/player/client.c @@ -1735,7 +1735,8 @@ static bool gen_property_change_event(struct mpv_handle *ctx) while (1) { if (ctx->cur_property_index >= ctx->num_properties) { - if (!ctx->new_property_events || !ctx->num_properties) + ctx->new_property_events &= ctx->num_properties > 0; + if (!ctx->new_property_events) break; ctx->new_property_events = false; ctx->cur_property_index = 0;