From cbdcb3df1fa5bb5144b1a43787d957e00ce0623f Mon Sep 17 00:00:00 2001 From: Jean-Yves Avenard Date: Tue, 15 Mar 2016 18:03:30 +1100 Subject: [PATCH] Bug 1246536: [webm] Only use discard padding information on last packet. r=kinetik MozReview-Commit-ID: 3MYm25HfX0N --HG-- extra : rebase_source : c4d657d232d852e341114d4f966362005c9c4087 --- dom/media/webm/WebMDemuxer.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dom/media/webm/WebMDemuxer.cpp b/dom/media/webm/WebMDemuxer.cpp index 20a703879c1d..096b2744ae52 100644 --- a/dom/media/webm/WebMDemuxer.cpp +++ b/dom/media/webm/WebMDemuxer.cpp @@ -582,7 +582,7 @@ WebMDemuxer::GetNextPacket(TrackInfo::TrackType aType, MediaRawDataQueue *aSampl sample->mDuration = next_tstamp - tstamp; sample->mOffset = holder->Offset(); sample->mKeyframe = isKeyframe; - if (discardPadding) { + if (discardPadding && i == count - 1) { uint8_t c[8]; BigEndian::writeInt64(&c[0], discardPadding); sample->mExtraData = new MediaByteBuffer;