Commit 3b2093703b for ffmpeg
commit 3b2093703b47c5342882ed723a060ec24a15e3cc
Author: Romain Beauxis <romain.beauxis@gmail.com>
Date: Sun Nov 1 09:07:30 2026 -0600
avformat/oggparseopus: flag the last packet of a link with AV_PKT_FLAG_EOS
A link ends with samples the decoder may still hold back, and the
next link does not continue its decoder state.
Flag the last packet of an EOS page, so that the decoder can output
them with the link they belong to.
diff --git a/libavformat/oggparseopus.c b/libavformat/oggparseopus.c
index 43840c003e..f01580878f 100644
--- a/libavformat/oggparseopus.c
+++ b/libavformat/oggparseopus.c
@@ -212,6 +212,8 @@ static int opus_packet(AVFormatContext *avf, int idx)
"Last packet was truncated to %d due to end trimming.\n",
os->pduration);
}
+ if (os->segp == os->nsegs)
+ os->pflags |= AV_PKT_FLAG_EOS;
}
return 0;