Repository navigation
fix: MPRIS seeked signals reporting old position instead of new - #1408
Endg4meZer0 wants to merge 1 commit into
Conversation
gavtroy
left a comment
There was a problem hiding this comment.
I'm not the someone knowledgeable you mentioned but it looks good to me.
pgaskin
left a comment
There was a problem hiding this comment.
Looks fine to me. I'll test this later.
On a side note, we might want to consider debouncing MPRIS signals.
|
Hey, is there any update on it? |
|
Not yet, I tend to do cmus maintenance in bursts since I don't currently have too much time to devote to it. |
pgaskin
left a comment
There was a problem hiding this comment.
PR looks fine wrt concurrency and locking. It also happens to fix the consumer loop potentially getting blocked on a dbus emit of a seeked event.
The flag implementation looks correct overall (it can't get dropped mistakenly), but there's a few other minor issues:
- Position may still be old if changed between
player_unlockand the next snapshot. - Not safe to call
player_seekfrom other threads. - Duplicate seeked event on startup if
resumeis enabled.
Side note: this change also means that failed seeks don't emit seeked, but that makes sense.
Fixing #1407, probably in a hacky way. Would've been great if someone knowledgeable took a look and said if it's OK as it is.