From e38bf89d7524c070b9831d1f5b37f7d432942ab0 Mon Sep 17 00:00:00 2001 From: Ryan VanderMeulen Date: Thu, 25 Jul 2013 10:31:48 -0400 Subject: [PATCH] Backed out changesets 73188e11f7b1 and 7111c04c1158 (bug 896353) for mochitest-1 crashes. --- content/media/MediaRecorder.cpp | 4 ++-- content/media/MediaRecorder.h | 2 -- content/media/webaudio/MediaStreamAudioDestinationNode.cpp | 6 ------ 3 files changed, 2 insertions(+), 10 deletions(-) diff --git a/content/media/MediaRecorder.cpp b/content/media/MediaRecorder.cpp index 919a5e51d94..f4a31b217a5 100644 --- a/content/media/MediaRecorder.cpp +++ b/content/media/MediaRecorder.cpp @@ -116,7 +116,6 @@ private: MediaRecorder::~MediaRecorder() { if (mTrackUnionStream) { - mStreamPort->Destroy(); mTrackUnionStream->Destroy(); } } @@ -193,7 +192,8 @@ MediaRecorder::Start(const Optional& aTimeSlice, ErrorResult& aResult) MOZ_ASSERT(mEncoder, "CreateEncoder failed"); mTrackUnionStream->SetAutofinish(true); - mStreamPort = mTrackUnionStream->AllocateInputPort(mStream->GetStream(), MediaInputPort::FLAG_BLOCK_OUTPUT); + nsRefPtr port = + mTrackUnionStream->AllocateInputPort(mStream->GetStream(), MediaInputPort::FLAG_BLOCK_OUTPUT); if (mEncoder) { mTrackUnionStream->AddListener(mEncoder); diff --git a/content/media/MediaRecorder.h b/content/media/MediaRecorder.h index 0a5e14217d8..85350ae33f7 100644 --- a/content/media/MediaRecorder.h +++ b/content/media/MediaRecorder.h @@ -110,8 +110,6 @@ protected: nsRefPtr mStream; // This media stream is used for notifying raw data to encoder and can be blocked. nsRefPtr mTrackUnionStream; - // This is used for destroing the inputport when destroy the mediaRecorder - nsRefPtr mStreamPort; // This object creates on start() and destroys in ~MediaRecorder. nsAutoPtr mEncodedBufferCache; // It specifies the container format as well as the audio and video capture formats. diff --git a/content/media/webaudio/MediaStreamAudioDestinationNode.cpp b/content/media/webaudio/MediaStreamAudioDestinationNode.cpp index c2e2b983200..0c99d700207 100644 --- a/content/media/webaudio/MediaStreamAudioDestinationNode.cpp +++ b/content/media/webaudio/MediaStreamAudioDestinationNode.cpp @@ -5,7 +5,6 @@ * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ #include "MediaStreamAudioDestinationNode.h" -#include "nsIDocument.h" #include "mozilla/dom/AudioStreamTrack.h" #include "mozilla/dom/MediaStreamAudioDestinationNodeBinding.h" #include "AudioNodeEngine.h" @@ -74,11 +73,6 @@ MediaStreamAudioDestinationNode::MediaStreamAudioDestinationNode(AudioContext* a MediaStreamDestinationEngine* engine = new MediaStreamDestinationEngine(this, tus); mStream = aContext->Graph()->CreateAudioNodeStream(engine, MediaStreamGraph::INTERNAL_STREAM); mPort = tus->AllocateInputPort(mStream, 0); - - nsIDocument* doc = aContext->GetParentObject()->GetExtantDoc(); - if (doc) { - mDOMStream->CombineWithPrincipal(doc->NodePrincipal()); - } } void