From 2a872c3865ad3446cbf64ed72dbfa846110d675d Mon Sep 17 00:00:00 2001 From: Romain Vimont Date: Wed, 16 Feb 2022 18:11:40 +0100 Subject: [PATCH] Fix fps_counter tick type The type uint32_t is not sufficient to store the result of sc_tick_now(). As a consequence, the FPS counter entered a live loop and caused a lock starvation (deadlock in practice). Refs ec871dd3f596a8183e37982821645ac5a5791fe0 Refs 682a6911735cb8f6dccd9653ce30b72f267235c6 --- app/src/fps_counter.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/src/fps_counter.c b/app/src/fps_counter.c index 25ee00eb..158e60ed 100644 --- a/app/src/fps_counter.c +++ b/app/src/fps_counter.c @@ -57,7 +57,7 @@ display_fps(struct fps_counter *counter) { // must be called with mutex locked static void -check_interval_expired(struct fps_counter *counter, uint32_t now) { +check_interval_expired(struct fps_counter *counter, sc_tick now) { if (now < counter->next_timestamp) { return; }