Bug 1168674: [ogg] P8. Set dts to pts value. r?brion
MozReview-Commit-ID: mYa2T6zln0
--- a/dom/media/ogg/OggCodecState.cpp
+++ b/dom/media/ogg/OggCodecState.cpp
@@ -209,18 +209,17 @@ RefPtr<MediaRawData> OggCodecState::Pack
RefPtr<MediaRawData> sample = new MediaRawData(packet->packet, packet->bytes);
int64_t end_tstamp = Time(packet->granulepos);
NS_ASSERTION(end_tstamp >= 0, "timestamp invalid");
int64_t duration = PacketDuration(packet);
NS_ASSERTION(duration >= 0, "duration invalid");
- sample->mTimecode = packet->granulepos;
- sample->mTime = end_tstamp - duration;
+ sample->mTimecode = sample->mTime = end_tstamp - duration;
sample->mDuration = duration;
sample->mKeyframe = IsKeyframe(packet);
// The packet's data now belongs to the ref-counted MediaRawData instance;
// free the ogg_packet structure only.
delete packet;
return sample;