From 789aa0a6953a9754bf47513d9a879de8125f1b05 Mon Sep 17 00:00:00 2001 From: William Wilgus Date: Wed, 11 Dec 2024 19:33:10 -0500 Subject: [PATCH] Scrobbler plugin remove logf size warnings using chris_s' trick to caste to 64 bit int Change-Id: I28cac7e301d272351d44527531b46f1e211141fc --- apps/plugins/lastfm_scrobbler.c | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/apps/plugins/lastfm_scrobbler.c b/apps/plugins/lastfm_scrobbler.c index df425edfe0..cb6a1a9d97 100644 --- a/apps/plugins/lastfm_scrobbler.c +++ b/apps/plugins/lastfm_scrobbler.c @@ -381,7 +381,8 @@ static bool track_is_unique(uint32_t hash1, uint32_t hash2) /* Found in MRU */ if ((i.hash1 == hash1) && (i.hash2 == hash2)) { - logf("SCROBBLER: hash [%lx, %lx] found in MRU @ %d", i.hash1, i.hash2, mru); + logf("SCROBBLER: hash [%jx, %jx] found in MRU @ %d", + (intmax_t)i.hash1, (intmax_t)i.hash2, mru); goto Found; } } @@ -395,11 +396,13 @@ static bool track_is_unique(uint32_t hash1, uint32_t hash2) } else { - logf("SCROBBLER: hash [%lx, %lx] evicted from MRU", i.hash1, i.hash2); + logf("SCROBBLER: hash [%jx, %jx] evicted from MRU", + (intmax_t) i.hash1, (intmax_t) i.hash2); } i = (struct hash64){.hash1 = hash1, .hash2 = hash2}; - logf("SCROBBLER: hash [%lx, %lx] added to MRU[%d]", i.hash1, i.hash2, mru_len); + logf("SCROBBLER: hash [%jx, %jx] added to MRU[%d]", + (intmax_t)i.hash1, (intmax_t)i.hash2, mru_len); Found: