Commit b536b26
playloop: unset last_chapter_flag when queueing non-chapter seeks
This fixes a race condition where if a non-chapter seek is queued
immediately after a chapter seek is queued, the chapter property may
become unavailable until a new file is loaded.
If multiple seeks are queued within the same playloop iteration, only
the last seek is executed. Because the chapter seek is never executed,
last_chapter_flag remains set and last_chapter_seek becomes -2, which
causes get_current_chapter to return -2, which makes the chapter
property unavailable.
Unset this (and also last_chapter_seek) immediately rather than
wait for seek execution, like chapter seeks set these immediately.1 parent b9249e0 commit b536b26
1 file changed
+5
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
279 | 279 | | |
280 | 280 | | |
281 | 281 | | |
282 | | - | |
283 | | - | |
284 | 282 | | |
285 | 283 | | |
286 | 284 | | |
| |||
450 | 448 | | |
451 | 449 | | |
452 | 450 | | |
| 451 | + | |
| 452 | + | |
| 453 | + | |
| 454 | + | |
| 455 | + | |
453 | 456 | | |
454 | 457 | | |
455 | 458 | | |
| |||
0 commit comments