Bug 1360123 P1 - don't bother creating a new track list in HTMLMediaElement::RemoveMediaTracks() r=jwwang
MozReview-Commit-ID: 6lmSxmKMrDK
This commit is contained in:
@@ -7366,14 +7366,12 @@ HTMLMediaElement::ConstructMediaTracks(const MediaInfo* aInfo)
|
||||
void
|
||||
HTMLMediaElement::RemoveMediaTracks()
|
||||
{
|
||||
AudioTrackList* audioList = AudioTracks();
|
||||
if (audioList) {
|
||||
audioList->RemoveTracks();
|
||||
if (mAudioTrackList) {
|
||||
mAudioTrackList->RemoveTracks();
|
||||
}
|
||||
|
||||
VideoTrackList* videoList = VideoTracks();
|
||||
if (videoList) {
|
||||
videoList->RemoveTracks();
|
||||
if (mVideoTrackList) {
|
||||
mVideoTrackList->RemoveTracks();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user