зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1325707: P1. Check returned value. r=gerald
This is really just for cleanliness perspective, as it can never happen, we always check that demuxing a packet succeeded first. MozReview-Commit-ID: FQ1yz16m9Ix --HG-- extra : rebase_source : 722ab3a828cadb07022a95b3ae456ef09781e61d
This commit is contained in:
Родитель
9b3d8d687b
Коммит
55981c9141
|
@ -1305,6 +1305,9 @@ OpusState::PacketOutAsMediaRawData()
|
|||
}
|
||||
|
||||
RefPtr<MediaRawData> data = OggCodecState::PacketOutAsMediaRawData();
|
||||
if (!data) {
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
if (data->mEOS && mPrevPacketGranulepos != -1) {
|
||||
// If this is the last packet, perform end trimming.
|
||||
|
|
|
@ -1342,6 +1342,9 @@ OggTrackDemuxer::NextSample()
|
|||
bool eos = packet->e_o_s;
|
||||
OggCodecState* state = mParent->GetTrackCodecState(mType);
|
||||
RefPtr<MediaRawData> data = state->PacketOutAsMediaRawData();
|
||||
if (!data) {
|
||||
return nullptr;
|
||||
}
|
||||
if (mType == TrackInfo::kAudioTrack) {
|
||||
data->mTrackInfo = mParent->mSharedAudioTrackInfo;
|
||||
}
|
||||
|
|
Загрузка…
Ссылка в новой задаче