Include decoder frame state in Android stream failure logs

This commit is contained in:
evgeny committed 2026-10-20 18:46:57 +02:00
1 parent ea5d1fcd45
commit ba26b14f16
1 file changed
+4 -1
@@ -43,7 +43,10 @@ internal class StreamDecodePump<F : StreamDecodePump.Frame>(
fun offer(frame: F, now: Long) {
// Уже запрошенный ответ может прийти после появления будущего output.
check(input == null && !ended) { "Decoder already owns a working frame" }
check(input == null && !ended) {
"Decoder already owns a working frame: incomingPTS=${frame.pts} inputPTS=${input?.pts} outputPTS=${output?.pts} " +
"ended=$ended inputs=$inputCount decoded=$outputCount shown=$shown"
}
// Новые данные после сетевой паузы получают собственное окно ожидания decoder progress.
if (lastInputAt < 0 || now - lastInputAt > 1_000_000) waitingSince = now
input = frame