Backed out 2 changesets (bug 1324548) for failing wpt at idlharness.https.window.html on a CLOSED TREE
authorAndreea Pavel <apavel@mozilla.com>
Wed, 03 Apr 2019 23:18:19 +0300
changeset 467825 835344b3ba42e288c97173efe2c6f8f21335f4d5
parent 467824 d61ab098b5f0e5341a3031fdd565973816949b1b
child 467826 4e8633fc0658bd761fd1547c65d28c1389d36510
push id35810
push useraciure@mozilla.com
push dateThu, 04 Apr 2019 04:33:36 +0000
treeherdermozilla-central@b72c02e34261 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
bugs1324548
milestone68.0a1
backs out055578135fba34c43339630f16e069052d19d5fc
7aefaab277fe390ed8537fce35c2a2f73ab54e97
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Backed out 2 changesets (bug 1324548) for failing wpt at idlharness.https.window.html on a CLOSED TREE Backed out changeset 055578135fba (bug 1324548) Backed out changeset 7aefaab277fe (bug 1324548)
dom/locales/en-US/chrome/dom/dom.properties
dom/media/MediaStreamTrack.cpp
dom/media/webaudio/AudioContext.cpp
dom/media/webaudio/AudioContext.h
dom/media/webaudio/MediaStreamTrackAudioSourceNode.cpp
dom/media/webaudio/MediaStreamTrackAudioSourceNode.h
dom/media/webaudio/moz.build
dom/media/webaudio/test/mochitest.ini
dom/media/webaudio/test/test_mediaStreamAudioSourceNodeNoGC.html
dom/media/webaudio/test/test_mediaStreamTrackAudioSourceNode.html
dom/media/webaudio/test/test_mediaStreamTrackAudioSourceNodeCrossOrigin.html
dom/media/webaudio/test/test_mediaStreamTrackAudioSourceNodeVideo.html
dom/tests/mochitest/general/test_interfaces.js
dom/webidl/AudioContext.webidl
dom/webidl/MediaStreamTrackAudioSourceNode.webidl
dom/webidl/moz.build
--- a/dom/locales/en-US/chrome/dom/dom.properties
+++ b/dom/locales/en-US/chrome/dom/dom.properties
@@ -100,18 +100,16 @@ MediaDecodeAudioDataUnknownError=An unkn
 # LOCALIZATION NOTE: Do not translate decodeAudioData.
 MediaDecodeAudioDataInvalidContent=The buffer passed to decodeAudioData contains invalid content which cannot be decoded successfully.
 # LOCALIZATION NOTE: Do not translate decodeAudioData.
 MediaDecodeAudioDataNoAudio=The buffer passed to decodeAudioData does not contain any audio.
 # LOCALIZATION NOTE: Do not translate HTMLMediaElement and createMediaElementSource.
 MediaElementAudioSourceNodeCrossOrigin=The HTMLMediaElement passed to createMediaElementSource has a cross-origin resource, the node will output silence.
 # LOCALIZATION NOTE: Do not translate MediaStream and createMediaStreamSource.
 MediaStreamAudioSourceNodeCrossOrigin=The MediaStream passed to createMediaStreamSource has a cross-origin resource, the node will output silence.
-# LOCALIZATION NOTE : Do not translate MediaStreamTrack and createMediaStreamTrackSource.
-MediaStreamTrackAudioSourceNodeCrossOrigin=The MediaStreamTrack passed to createMediaStreamTrackSource is a cross-origin resource, the node will output silence.
 # LOCALIZATION NOTE: Do not translate HTMLMediaElement and MediaStream.
 MediaElementAudioCaptureOfMediaStreamError=The captured HTMLMediaElement is playing a MediaStream. Applying volume or mute status is not currently supported.
 MediaLoadExhaustedCandidates=All candidate resources failed to load. Media load paused.
 MediaLoadSourceMissingSrc=<source> element has no “src” attribute. Media resource load failed.
 MediaStreamAudioSourceNodeDifferentRate=Connecting AudioNodes from AudioContexts with different sample-rate is currently not supported.
 # LOCALIZATION NOTE: Do not translate ConvolverNode
 ConvolverNodeAllocationError=Out-of-memory error when instantiating a ConvolverNode: the node will output silence.
 # LOCALIZATION NOTE: %1$S is the Http error code the server returned (e.g. 404, 500, etc), %2$S is the URL of the media resource which failed to load.
--- a/dom/media/MediaStreamTrack.cpp
+++ b/dom/media/MediaStreamTrack.cpp
@@ -107,20 +107,16 @@ class MediaStreamTrack::MSGListener : pu
 
   void NotifyRemoved() override {
     // `mTrack` is a WeakPtr and must be destroyed on main thread.
     // We dispatch ourselves to main thread here in case the MediaStreamGraph
     // is holding the last reference to us.
     mGraph->DispatchToMainThreadStableState(
         NS_NewRunnableFunction("MediaStreamTrack::MSGListener::mTrackReleaser",
                                [self = RefPtr<MSGListener>(this)]() {}));
-
-    mGraph->Dispatch(NS_NewRunnableFunction(
-        "MediaStreamTrack::MSGListener::DoNotifyEnded",
-        [self = RefPtr<MSGListener>(this)]() { self->DoNotifyEnded(); }));
   }
 
   void DoNotifyEnded() {
     MOZ_ASSERT(NS_IsMainThread());
 
     if (!mTrack) {
       return;
     }
--- a/dom/media/webaudio/AudioContext.cpp
+++ b/dom/media/webaudio/AudioContext.cpp
@@ -26,17 +26,16 @@
 #include "mozilla/dom/ConvolverNodeBinding.h"
 #include "mozilla/dom/DelayNodeBinding.h"
 #include "mozilla/dom/DynamicsCompressorNodeBinding.h"
 #include "mozilla/dom/GainNodeBinding.h"
 #include "mozilla/dom/IIRFilterNodeBinding.h"
 #include "mozilla/dom/HTMLMediaElement.h"
 #include "mozilla/dom/MediaElementAudioSourceNodeBinding.h"
 #include "mozilla/dom/MediaStreamAudioSourceNodeBinding.h"
-#include "mozilla/dom/MediaStreamTrackAudioSourceNodeBinding.h"
 #include "mozilla/dom/OfflineAudioContextBinding.h"
 #include "mozilla/dom/OscillatorNodeBinding.h"
 #include "mozilla/dom/PannerNodeBinding.h"
 #include "mozilla/dom/PeriodicWaveBinding.h"
 #include "mozilla/dom/Promise.h"
 #include "mozilla/dom/StereoPannerNodeBinding.h"
 #include "mozilla/dom/WaveShaperNodeBinding.h"
 #include "mozilla/dom/Worklet.h"
@@ -58,17 +57,16 @@
 #include "DelayNode.h"
 #include "DynamicsCompressorNode.h"
 #include "GainNode.h"
 #include "IIRFilterNode.h"
 #include "js/ArrayBuffer.h"  // JS::StealArrayBufferContents
 #include "MediaElementAudioSourceNode.h"
 #include "MediaStreamAudioDestinationNode.h"
 #include "MediaStreamAudioSourceNode.h"
-#include "MediaStreamTrackAudioSourceNode.h"
 #include "MediaStreamGraph.h"
 #include "nsContentUtils.h"
 #include "nsIScriptError.h"
 #include "nsNetCID.h"
 #include "nsNetUtil.h"
 #include "nsPIDOMWindow.h"
 #include "nsPrintfCString.h"
 #include "nsRFPService.h"
@@ -421,25 +419,16 @@ already_AddRefed<MediaStreamAudioSourceN
 AudioContext::CreateMediaStreamSource(DOMMediaStream& aMediaStream,
                                       ErrorResult& aRv) {
   MediaStreamAudioSourceOptions options;
   options.mMediaStream = aMediaStream;
 
   return MediaStreamAudioSourceNode::Create(*this, options, aRv);
 }
 
-already_AddRefed<MediaStreamTrackAudioSourceNode>
-AudioContext::CreateMediaStreamTrackSource(MediaStreamTrack& aMediaStreamTrack,
-                                           ErrorResult& aRv) {
-  MediaStreamTrackAudioSourceOptions options;
-  options.mMediaStreamTrack = aMediaStreamTrack;
-
-  return MediaStreamTrackAudioSourceNode::Create(*this, options, aRv);
-}
-
 already_AddRefed<GainNode> AudioContext::CreateGain(ErrorResult& aRv) {
   return GainNode::Create(*this, GainOptions(), aRv);
 }
 
 already_AddRefed<WaveShaperNode> AudioContext::CreateWaveShaper(
     ErrorResult& aRv) {
   return WaveShaperNode::Create(*this, WaveShaperOptions(), aRv);
 }
--- a/dom/media/webaudio/AudioContext.h
+++ b/dom/media/webaudio/AudioContext.h
@@ -62,18 +62,16 @@ class DelayNode;
 class DynamicsCompressorNode;
 class GainNode;
 class GlobalObject;
 class HTMLMediaElement;
 class IIRFilterNode;
 class MediaElementAudioSourceNode;
 class MediaStreamAudioDestinationNode;
 class MediaStreamAudioSourceNode;
-class MediaStreamTrack;
-class MediaStreamTrackAudioSourceNode;
 class OscillatorNode;
 class PannerNode;
 class ScriptProcessorNode;
 class StereoPannerNode;
 class WaveShaperNode;
 class Worklet;
 class PeriodicWave;
 struct PeriodicWaveConstraints;
@@ -243,19 +241,16 @@ class AudioContext final : public DOMEve
   already_AddRefed<GainNode> CreateGain(ErrorResult& aRv);
 
   already_AddRefed<WaveShaperNode> CreateWaveShaper(ErrorResult& aRv);
 
   already_AddRefed<MediaElementAudioSourceNode> CreateMediaElementSource(
       HTMLMediaElement& aMediaElement, ErrorResult& aRv);
   already_AddRefed<MediaStreamAudioSourceNode> CreateMediaStreamSource(
       DOMMediaStream& aMediaStream, ErrorResult& aRv);
-  already_AddRefed<MediaStreamTrackAudioSourceNode>
-  CreateMediaStreamTrackSource(MediaStreamTrack& aMediaStreamTrack,
-                               ErrorResult& aRv);
 
   already_AddRefed<DelayNode> CreateDelay(double aMaxDelayTime,
                                           ErrorResult& aRv);
 
   already_AddRefed<PannerNode> CreatePanner(ErrorResult& aRv);
 
   already_AddRefed<ConvolverNode> CreateConvolver(ErrorResult& aRv);
 
deleted file mode 100644
--- a/dom/media/webaudio/MediaStreamTrackAudioSourceNode.cpp
+++ /dev/null
@@ -1,192 +0,0 @@
-/* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
-/* vim: set ts=8 sts=2 et sw=2 tw=80: */
-/* This Source Code Form is subject to the terms of the Mozilla Public
- * License, v. 2.0. If a copy of the MPL was not distributed with this
- * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
-
-#include "MediaStreamTrackAudioSourceNode.h"
-#include "mozilla/dom/MediaStreamTrackAudioSourceNodeBinding.h"
-#include "AudioNodeEngine.h"
-#include "AudioNodeExternalInputStream.h"
-#include "AudioStreamTrack.h"
-#include "mozilla/dom/Document.h"
-#include "mozilla/CORSMode.h"
-#include "nsContentUtils.h"
-#include "nsIScriptError.h"
-
-namespace mozilla {
-namespace dom {
-
-NS_IMPL_CYCLE_COLLECTION_CLASS(MediaStreamTrackAudioSourceNode)
-
-NS_IMPL_CYCLE_COLLECTION_UNLINK_BEGIN(MediaStreamTrackAudioSourceNode)
-  tmp->Destroy();
-  NS_IMPL_CYCLE_COLLECTION_UNLINK(mInputTrack)
-NS_IMPL_CYCLE_COLLECTION_UNLINK_END_INHERITED(AudioNode)
-
-NS_IMPL_CYCLE_COLLECTION_TRAVERSE_BEGIN_INHERITED(
-    MediaStreamTrackAudioSourceNode, AudioNode)
-  NS_IMPL_CYCLE_COLLECTION_TRAVERSE(mInputTrack)
-NS_IMPL_CYCLE_COLLECTION_TRAVERSE_END
-
-NS_INTERFACE_MAP_BEGIN_CYCLE_COLLECTION(MediaStreamTrackAudioSourceNode)
-NS_INTERFACE_MAP_END_INHERITING(AudioNode)
-
-NS_IMPL_ADDREF_INHERITED(MediaStreamTrackAudioSourceNode, AudioNode)
-NS_IMPL_RELEASE_INHERITED(MediaStreamTrackAudioSourceNode, AudioNode)
-
-MediaStreamTrackAudioSourceNode::MediaStreamTrackAudioSourceNode(
-    AudioContext* aContext)
-    : AudioNode(aContext, 2, ChannelCountMode::Max,
-                ChannelInterpretation::Speakers),
-      mTrackListener(this) {}
-
-/* static */ already_AddRefed<MediaStreamTrackAudioSourceNode>
-MediaStreamTrackAudioSourceNode::Create(
-    AudioContext& aAudioContext,
-    const MediaStreamTrackAudioSourceOptions& aOptions, ErrorResult& aRv) {
-  if (aAudioContext.IsOffline()) {
-    aRv.Throw(NS_ERROR_DOM_NOT_SUPPORTED_ERR);
-    return nullptr;
-  }
-
-  if (aAudioContext.Graph() != aOptions.mMediaStreamTrack->Graph()) {
-    nsCOMPtr<nsPIDOMWindowInner> pWindow = aAudioContext.GetParentObject();
-    Document* document = pWindow ? pWindow->GetExtantDoc() : nullptr;
-    nsContentUtils::ReportToConsole(nsIScriptError::warningFlag,
-                                    NS_LITERAL_CSTRING("Web Audio"), document,
-                                    nsContentUtils::eDOM_PROPERTIES,
-                                    "MediaStreamAudioSourceNodeDifferentRate");
-    aRv.Throw(NS_ERROR_DOM_NOT_SUPPORTED_ERR);
-    return nullptr;
-  }
-
-  RefPtr<MediaStreamTrackAudioSourceNode> node =
-      new MediaStreamTrackAudioSourceNode(&aAudioContext);
-
-  node->Init(aOptions.mMediaStreamTrack, aRv);
-  if (aRv.Failed()) {
-    return nullptr;
-  }
-
-  return node.forget();
-}
-
-void MediaStreamTrackAudioSourceNode::Init(MediaStreamTrack* aMediaStreamTrack,
-                                           ErrorResult& aRv) {
-  MOZ_ASSERT(aMediaStreamTrack);
-
-  if (!aMediaStreamTrack->AsAudioStreamTrack()) {
-    mTrackListener.NotifyEnded(nullptr);
-    aRv.Throw(NS_ERROR_DOM_INVALID_STATE_ERR);
-    return;
-  }
-
-  MediaStreamGraph* graph = Context()->Graph();
-
-  AudioNodeEngine* engine = new MediaStreamTrackAudioSourceNodeEngine(this);
-  mStream = AudioNodeExternalInputStream::Create(graph, engine);
-
-  MOZ_ASSERT(mStream);
-
-  mInputTrack = aMediaStreamTrack;
-  ProcessedMediaStream* outputStream =
-      static_cast<ProcessedMediaStream*>(mStream.get());
-  mInputPort = mInputTrack->ForwardTrackContentsTo(outputStream);
-  PrincipalChanged(mInputTrack);  // trigger enabling/disabling of the connector
-  mInputTrack->AddPrincipalChangeObserver(this);
-
-  mInputTrack->AddConsumer(&mTrackListener);
-}
-
-void MediaStreamTrackAudioSourceNode::Destroy() {
-  if (mInputTrack) {
-    mInputTrack->RemovePrincipalChangeObserver(this);
-    mInputTrack->RemoveConsumer(&mTrackListener);
-    mInputTrack = nullptr;
-  }
-  mTrackListener.NotifyEnded(mInputTrack);
-
-  if (mInputPort) {
-    mInputPort->Destroy();
-    mInputPort = nullptr;
-  }
-}
-
-MediaStreamTrackAudioSourceNode::~MediaStreamTrackAudioSourceNode() {
-  Destroy();
-}
-
-/**
- * Changes the principal. Note that this will be called on the main thread, but
- * changes will be enacted on the MediaStreamGraph thread. If the principal
- * change results in the document principal losing access to the stream, then
- * there needs to be other measures in place to ensure that any media that is
- * governed by the new stream principal is not available to the MediaStreamGraph
- * before this change completes. Otherwise, a site could get access to
- * media that they are not authorized to receive.
- *
- * One solution is to block the altered content, call this method, then dispatch
- * another change request to the MediaStreamGraph thread that allows the content
- * under the new principal to flow. This might be unnecessary if the principal
- * change is changing to be the document principal.
- */
-void MediaStreamTrackAudioSourceNode::PrincipalChanged(
-    MediaStreamTrack* aMediaStreamTrack) {
-  MOZ_ASSERT(aMediaStreamTrack == mInputTrack);
-
-  bool subsumes = false;
-  Document* doc = nullptr;
-  if (nsPIDOMWindowInner* parent = Context()->GetParentObject()) {
-    doc = parent->GetExtantDoc();
-    if (doc) {
-      nsIPrincipal* docPrincipal = doc->NodePrincipal();
-      nsIPrincipal* trackPrincipal = aMediaStreamTrack->GetPrincipal();
-      if (!trackPrincipal ||
-          NS_FAILED(docPrincipal->Subsumes(trackPrincipal, &subsumes))) {
-        subsumes = false;
-      }
-    }
-  }
-  auto stream = static_cast<AudioNodeExternalInputStream*>(mStream.get());
-  bool enabled = subsumes || aMediaStreamTrack->GetCORSMode() != CORS_NONE;
-  stream->SetInt32Parameter(MediaStreamTrackAudioSourceNodeEngine::ENABLE,
-                            enabled);
-  fprintf(stderr, "NOW: %s", enabled ? "enabled" : "disabled");
-
-  if (!enabled && doc) {
-    nsContentUtils::ReportToConsole(
-        nsIScriptError::warningFlag, NS_LITERAL_CSTRING("Web Audio"), doc,
-        nsContentUtils::eDOM_PROPERTIES, CrossOriginErrorString());
-  }
-}
-
-size_t MediaStreamTrackAudioSourceNode::SizeOfExcludingThis(
-    MallocSizeOf aMallocSizeOf) const {
-  size_t amount = AudioNode::SizeOfExcludingThis(aMallocSizeOf);
-  if (mInputPort) {
-    amount += mInputPort->SizeOfIncludingThis(aMallocSizeOf);
-  }
-  return amount;
-}
-
-size_t MediaStreamTrackAudioSourceNode::SizeOfIncludingThis(
-    MallocSizeOf aMallocSizeOf) const {
-  return aMallocSizeOf(this) + SizeOfExcludingThis(aMallocSizeOf);
-}
-
-void MediaStreamTrackAudioSourceNode::DestroyMediaStream() {
-  if (mInputPort) {
-    mInputPort->Destroy();
-    mInputPort = nullptr;
-  }
-  AudioNode::DestroyMediaStream();
-}
-
-JSObject* MediaStreamTrackAudioSourceNode::WrapObject(
-    JSContext* aCx, JS::Handle<JSObject*> aGivenProto) {
-  return MediaStreamTrackAudioSourceNode_Binding::Wrap(aCx, this, aGivenProto);
-}
-
-}  // namespace dom
-}  // namespace mozilla
deleted file mode 100644
--- a/dom/media/webaudio/MediaStreamTrackAudioSourceNode.h
+++ /dev/null
@@ -1,115 +0,0 @@
-/* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
-/* vim: set ts=8 sts=2 et sw=2 tw=80: */
-/* This Source Code Form is subject to the terms of the Mozilla Public
- * License, v. 2.0. If a copy of the MPL was not distributed with this
- * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
-
-#ifndef MediaStreamTrackAudioSourceNode_h_
-#define MediaStreamTrackAudioSourceNode_h_
-
-#include "AudioNode.h"
-#include "AudioNodeEngine.h"
-#include "mozilla/WeakPtr.h"
-
-namespace mozilla {
-
-namespace dom {
-
-class AudioContext;
-struct MediaStreamTrackAudioSourceOptions;
-
-class MediaStreamTrackAudioSourceNodeEngine final : public AudioNodeEngine {
- public:
-  explicit MediaStreamTrackAudioSourceNodeEngine(AudioNode* aNode)
-      : AudioNodeEngine(aNode), mEnabled(false) {}
-
-  bool IsEnabled() const { return mEnabled; }
-  enum Parameters { ENABLE };
-  void SetInt32Parameter(uint32_t aIndex, int32_t aValue) override {
-    switch (aIndex) {
-      case ENABLE:
-        mEnabled = !!aValue;
-        break;
-      default:
-        NS_ERROR("MediaStreamTrackAudioSourceNodeEngine bad parameter index");
-    }
-  }
-
- private:
-  bool mEnabled;
-};
-
-class MediaStreamTrackAudioSourceNode
-    : public AudioNode,
-      public PrincipalChangeObserver<MediaStreamTrack>,
-      public SupportsWeakPtr<MediaStreamTrackAudioSourceNode> {
- public:
-  static already_AddRefed<MediaStreamTrackAudioSourceNode> Create(
-      AudioContext& aContext,
-      const MediaStreamTrackAudioSourceOptions& aOptions, ErrorResult& aRv);
-
-  NS_DECL_ISUPPORTS_INHERITED
-  MOZ_DECLARE_WEAKREFERENCE_TYPENAME(MediaStreamTrackAudioSourceNode)
-  NS_DECL_CYCLE_COLLECTION_CLASS_INHERITED(MediaStreamTrackAudioSourceNode,
-                                           AudioNode)
-
-  static already_AddRefed<MediaStreamTrackAudioSourceNode> Constructor(
-      const GlobalObject& aGlobal, AudioContext& aAudioContext,
-      const MediaStreamTrackAudioSourceOptions& aOptions, ErrorResult& aRv) {
-    return Create(aAudioContext, aOptions, aRv);
-  }
-
-  JSObject* WrapObject(JSContext* aCx,
-                       JS::Handle<JSObject*> aGivenProto) override;
-
-  void DestroyMediaStream() override;
-
-  uint16_t NumberOfInputs() const override { return 0; }
-
-  const char* NodeType() const override {
-    return "MediaStreamTrackAudioSourceNode";
-  }
-
-  virtual const char* CrossOriginErrorString() const {
-    return "MediaStreamTrackAudioSourceNodeCrossOrigin";
-  }
-
-  size_t SizeOfExcludingThis(MallocSizeOf aMallocSizeOf) const override;
-  size_t SizeOfIncludingThis(MallocSizeOf aMallocSizeOf) const override;
-
-  // From PrincipalChangeObserver<MediaStreamTrack>.
-  void PrincipalChanged(MediaStreamTrack* aMediaStreamTrack) override;
-
- protected:
-  explicit MediaStreamTrackAudioSourceNode(AudioContext* aContext);
-  void Init(MediaStreamTrack* aMediaStreamTrack, ErrorResult& aRv);
-  void Destroy();
-  virtual ~MediaStreamTrackAudioSourceNode();
-
-  class TrackListener : public MediaStreamTrackConsumer {
-   public:
-    explicit TrackListener(MediaStreamTrackAudioSourceNode* aNode)
-        : mNode(aNode) {}
-
-    void NotifyEnded(MediaStreamTrack* aTrack) override {
-      if (mNode) {
-        mNode->MarkInactive();
-        mNode->DestroyMediaStream();
-        mNode = nullptr;
-      }
-    }
-
-   private:
-    WeakPtr<MediaStreamTrackAudioSourceNode> mNode;
-  };
-
- private:
-  RefPtr<MediaInputPort> mInputPort;
-  RefPtr<MediaStreamTrack> mInputTrack;
-  TrackListener mTrackListener;
-};
-
-}  // namespace dom
-}  // namespace mozilla
-
-#endif
--- a/dom/media/webaudio/moz.build
+++ b/dom/media/webaudio/moz.build
@@ -61,17 +61,16 @@ EXPORTS.mozilla.dom += [
     'ConvolverNode.h',
     'DelayNode.h',
     'DynamicsCompressorNode.h',
     'GainNode.h',
     'IIRFilterNode.h',
     'MediaElementAudioSourceNode.h',
     'MediaStreamAudioDestinationNode.h',
     'MediaStreamAudioSourceNode.h',
-    'MediaStreamTrackAudioSourceNode.h',
     'OscillatorNode.h',
     'PannerNode.h',
     'PeriodicWave.h',
     'ScriptProcessorNode.h',
     'StereoPannerNode.h',
     'WaveShaperNode.h',
 ]
 
@@ -106,17 +105,16 @@ UNIFIED_SOURCES += [
     'DynamicsCompressorNode.cpp',
     'FFTBlock.cpp',
     'GainNode.cpp',
     'IIRFilterNode.cpp',
     'MediaBufferDecoder.cpp',
     'MediaElementAudioSourceNode.cpp',
     'MediaStreamAudioDestinationNode.cpp',
     'MediaStreamAudioSourceNode.cpp',
-    'MediaStreamTrackAudioSourceNode.cpp',
     'OscillatorNode.cpp',
     'PannerNode.cpp',
     'PeriodicWave.cpp',
     'ScriptProcessorNode.cpp',
     'StereoPannerNode.cpp',
     'ThreeDPoint.cpp',
     'WaveShaperNode.cpp',
     'WebAudioUtils.cpp',
--- a/dom/media/webaudio/test/mochitest.ini
+++ b/dom/media/webaudio/test/mochitest.ini
@@ -191,19 +191,16 @@ skip-if = toolkit == 'android' # bug 114
 [test_mediaStreamAudioDestinationNode.html]
 [test_mediaStreamAudioSourceNode.html]
 [test_mediaStreamAudioSourceNodeCrossOrigin.html]
 tags=capturestream
 [test_mediaStreamAudioSourceNodeNoGC.html]
 [test_mediaStreamAudioSourceNodePassThrough.html]
 [test_mediaStreamAudioSourceNodeResampling.html]
 tags=capturestream
-[test_mediaStreamTrackAudioSourceNode.html]
-[test_mediaStreamTrackAudioSourceNodeVideo.html]
-[test_mediaStreamTrackAudioSourceNodeCrossOrigin.html]
 [test_mixingRules.html]
 skip-if = toolkit == 'android' # bug 1091965
 [test_nodeToParamConnection.html]
 [test_nodeCreationDocumentGone.html]
 [test_notAllowedToStartAudioContextGC.html]
 [test_OfflineAudioContext.html]
 [test_offlineDestinationChannelCountLess.html]
 [test_offlineDestinationChannelCountMore.html]
--- a/dom/media/webaudio/test/test_mediaStreamAudioSourceNodeNoGC.html
+++ b/dom/media/webaudio/test/test_mediaStreamAudioSourceNodeNoGC.html
@@ -9,54 +9,66 @@
 <body>
 <pre id="test">
 <script class="testbody" type="text/javascript">
 SimpleTest.waitForExplicitFinish();
 SimpleTest.requestFlakyTimeout("gUM and WebAudio data is async to main thread. " +
                                "We need a timeout to see that something does " +
                                "NOT happen to data.");
 
-let context = new AudioContext();
-let analyser = context.createAnalyser();
+var context = new AudioContext();
+var analyser = context.createAnalyser();
 
 function wait(millis, resolveWithThis) {
   return new Promise(resolve => setTimeout(() => resolve(resolveWithThis), millis));
 }
 
 function binIndexForFrequency(frequency) {
   return 1 + Math.round(frequency * analyser.fftSize / context.sampleRate);
 }
 
 function waitForAudio(analysisFunction, cancelPromise) {
-  let data = new Uint8Array(analyser.frequencyBinCount);
-  let cancelled = false;
-  let cancelledMsg = "";
+  var data = new Uint8Array(analyser.frequencyBinCount);
+  var cancelled = false;
+  var cancelledMsg = "";
   cancelPromise.then(msg => {
     cancelled = true;
     cancelledMsg = msg;
   });
   return new Promise((resolve, reject) => {
-    let loop = () => {
+    var loop = () => {
       analyser.getByteFrequencyData(data);
       if (cancelled) {
         reject(new Error("waitForAudio cancelled: " + cancelledMsg));
         return;
       }
       if (analysisFunction(data)) {
         resolve();
         return;
       }
       requestAnimationFrame(loop);
     };
     loop();
   });
 }
 
-async function test(sourceNode) {
+SpecialPowers.pushPrefEnv({
+  set: [
+    // This test expects the fake audio device, specifically for the tones
+    // it outputs. Explicitly disable the audio loopback device and enable
+    // fake streams.
+    ['media.audio_loopback_dev', ''],
+    ['media.navigator.streams.fake', true]
+  ]
+}).then(async () => {
   try {
+    let stream = await navigator.mediaDevices.getUserMedia({audio: true});
+    stream.onended = () => ended = true;
+    let source = context.createMediaStreamSource(stream);
+    source.connect(analyser);
     await analyser.connect(context.destination);
 
     ok(true, "Waiting for audio to pass through the analyser")
     await waitForAudio(arr => arr[binIndexForFrequency(1000)] > 200,
                        wait(60000, "Timeout waiting for audio"));
 
     ok(true, "Audio was detected by the analyser. Forcing CC.");
     SpecialPowers.forceCC();
@@ -66,49 +78,18 @@ async function test(sourceNode) {
 
     info("Checking that GC didn't destroy the stream or source node");
     await waitForAudio(arr => arr[binIndexForFrequency(1000)] < 50,
                        wait(5000, "Timeout waiting for GC (timeout OK)"))
                   .then(() => Promise.reject("Audio stopped unexpectedly"),
                         () => Promise.resolve());
 
     ok(true, "Audio is still flowing");
+    SimpleTest.finish();
   } catch(e) {
     ok(false, "Error executing test: " + e + (e.stack ? "\n" + e.stack : ""));
     SimpleTest.finish();
   }
-}
-
-(async function() {
-  try {
-    await SpecialPowers.pushPrefEnv({
-      set: [
-        // This test expects the fake audio device, specifically for the tones
-        // it outputs. Explicitly disable the audio loopback device and enable
-        // fake streams.
-        ['media.audio_loopback_dev', ''],
-        ['media.navigator.streams.fake', true]
-      ]
-    });
-
-    // Test stream source GC
-    let stream = await navigator.mediaDevices.getUserMedia({audio: true});
-    let source = context.createMediaStreamSource(stream);
-    stream = null;
-    source.connect(analyser);
-    await test(source);
-
-    // Test track source GC
-    stream = await navigator.mediaDevices.getUserMedia({audio: true});
-    source = context.createMediaStreamTrackSource(stream.getAudioTracks()[0]);
-    stream = null;
-    source.connect(analyser);
-    await test(source);
-  } catch(e) {
-    ok(false, `Error executing test: ${e}${e.stack ? "\n" + e.stack : ""}`);
-  } finally {
-    SimpleTest.finish();
-  }
-})();
+});
 </script>
 </pre>
 </body>
 </html>
deleted file mode 100644
--- a/dom/media/webaudio/test/test_mediaStreamTrackAudioSourceNode.html
+++ /dev/null
@@ -1,54 +0,0 @@
-<!DOCTYPE HTML>
-<html>
-<meta charset="utf-8">
-<head>
-  <title>Test MediaStreamTrackAudioSourceNode processing is correct</title>
-  <script type="text/javascript" src="/tests/SimpleTest/SimpleTest.js"></script>
-  <script type="text/javascript" src="webaudio.js"></script>
-  <link rel="stylesheet" type="text/css" href="/tests/SimpleTest/test.css" />
-</head>
-<body>
-<pre id="test">
-<script class="testbody" type="text/javascript">
-
-function createBuffer(context) {
-  let buffer = context.createBuffer(2, 2048, context.sampleRate);
-  for (let i = 0; i < 2048; ++i) {
-    buffer.getChannelData(0)[i] = Math.sin(440 * 2 * Math.PI * i / context.sampleRate);
-    buffer.getChannelData(1)[i] = -buffer.getChannelData(0)[i];
-  }
-  return buffer;
-}
-
-let gTest = {
-  length: 2048,
-  skipOfflineContextTests: true,
-  createGraph: function(context) {
-    let sourceGraph = new AudioContext();
-    let source = sourceGraph.createBufferSource();
-    source.buffer = createBuffer(context);
-    let dest = sourceGraph.createMediaStreamDestination();
-    source.connect(dest);
-
-    // Extract first audio track from dest.stream
-    let track = dest.stream.getAudioTracks()[0];
-
-    source.start(0);
-
-    let mediaStreamTrackSource = new MediaStreamTrackAudioSourceNode(context, { mediaStreamTrack: track });
-    // channelCount and channelCountMode should have no effect
-    mediaStreamTrackSource.channelCount = 1;
-    mediaStreamTrackSource.channelCountMode = "explicit";
-    return mediaStreamTrackSource;
-  },
-  createExpectedBuffers: function(context) {
-    return createBuffer(context);
-  },
-};
-
-runTest();
-
-</script>
-</pre>
-</body>
-</html>
deleted file mode 100644
--- a/dom/media/webaudio/test/test_mediaStreamTrackAudioSourceNodeCrossOrigin.html
+++ /dev/null
@@ -1,53 +0,0 @@
-<!DOCTYPE HTML>
-<html>
-<meta charset="utf-8">
-<head>
-<title>Test MediaStreamTrackAudioSourceNode doesn't get data from cross-origin media resources</title>
-<script type="text/javascript" src="/tests/SimpleTest/SimpleTest.js"></script>
-<link rel="stylesheet" type="text/css" href="/tests/SimpleTest/test.css" />
-</head>
-<body>
-<pre id="test">
-<script class="testbody" type="text/javascript">
-SimpleTest.waitForExplicitFinish();
-
-const CROSS_ORIGIN_URL = "http://example.org:80/tests/dom/media/webaudio/test/sine-440-10s.opus"
-let iterationCount = 0;
-let context = null;
-
-function processSamples(e) {
-  ++iterationCount;
-
-  let buf = e.inputBuffer.getChannelData(0);
-  let nonzeroSamplesThisBuffer = 0;
-  for (let i = 0; i < buf.length; ++i) {
-    if (buf[i] != 0) {
-      ++nonzeroSamplesThisBuffer;
-    }
-  }
-  is(nonzeroSamplesThisBuffer, 0,
-     "a source that is cross origin cannot be inspected by Web Audio");
-
-  if (iterationCount == 40) {
-    sp = null;
-    context.close();
-    SimpleTest.finish();
-  }
-}
-
-let audio = new Audio();
-audio.src = CROSS_ORIGIN_URL;
-audio.onloadedmetadata = function () {
-  context = new AudioContext();
-  let stream = audio.mozCaptureStream();
-  let track = stream.getAudioTracks()[0];
-  let node = context.createMediaStreamTrackSource(track);
-  node.connect(context.destination);
-  sp = context.createScriptProcessor(2048, 1);
-  sp.onaudioprocess = processSamples;
-  node.connect(sp);
-}
-
-</script>
-</pre>
-</body>
deleted file mode 100644
--- a/dom/media/webaudio/test/test_mediaStreamTrackAudioSourceNodeVideo.html
+++ /dev/null
@@ -1,27 +0,0 @@
-<!DOCTYPE HTML>
-<html>
-<meta charset="utf-8">
-<head>
-  <title>Test MediaStreamTrackAudioSourceNode throw video track</title>
-  <script type="text/javascript" src="/tests/SimpleTest/SimpleTest.js"></script>
-  <script type="text/javascript" src="/tests/dom/media/webaudio/test/webaudio.js"></script>
-  <script type="text/javascript" src="/tests/dom/media/tests/mochitest/head.js"></script>
-  <link rel="stylesheet" type="text/css" href="/tests/SimpleTest/test.css" />
-</head>
-<body>
-<pre id="test">
-<script class="testbody" type="text/javascript">
-  let context = new AudioContext();
-  let canvas = document.createElement("canvas");
-  canvas.getContext("2d");
-  let track = canvas.captureStream().getTracks()[0];
-
-  expectException(() => {
-    let mediaStreamTrackSource = new MediaStreamTrackAudioSourceNode(
-      context,
-      { mediaStreamTrack: track });
-  }, DOMException.INVALID_STATE_ERR);
-</script>
-</pre>
-</body>
-</html>
--- a/dom/tests/mochitest/general/test_interfaces.js
+++ b/dom/tests/mochitest/general/test_interfaces.js
@@ -651,18 +651,16 @@ var interfaceNamesInGlobalScope =
     {name: "MediaSource", insecureContext: true},
 // IMPORTANT: Do not change this list without review from a DOM peer!
     {name: "MediaStream", insecureContext: true},
 // IMPORTANT: Do not change this list without review from a DOM peer!
     {name: "MediaStreamAudioDestinationNode", insecureContext: true},
 // IMPORTANT: Do not change this list without review from a DOM peer!
     {name: "MediaStreamAudioSourceNode", insecureContext: true},
 // IMPORTANT: Do not change this list without review from a DOM peer!
-    {name: "MediaStreamTrackAudioSourceNode", insecureContext: true},
-// IMPORTANT: Do not change this list without review from a DOM peer!
     {name: "MediaStreamEvent", insecureContext: true},
 // IMPORTANT: Do not change this list without review from a DOM peer!
     {name: "MediaStreamTrackEvent", insecureContext: true},
 // IMPORTANT: Do not change this list without review from a DOM peer!
     {name: "MediaStreamTrack", insecureContext: true},
 // IMPORTANT: Do not change this list without review from a DOM peer!
     {name: "MerchantValidationEvent", insecureContext: false, desktop: true, nightly: true, linux: false, disabled: true},
 // IMPORTANT: Do not change this list without review from a DOM peer!
--- a/dom/webidl/AudioContext.webidl
+++ b/dom/webidl/AudioContext.webidl
@@ -27,14 +27,13 @@ interface AudioContext : BaseAudioContex
     Promise<void> close();
 
     [NewObject, Throws]
     MediaElementAudioSourceNode createMediaElementSource(HTMLMediaElement mediaElement);
 
     [NewObject, Throws]
     MediaStreamAudioSourceNode createMediaStreamSource(MediaStream mediaStream);
 
-    [NewObject, Throws]
-    MediaStreamTrackAudioSourceNode createMediaStreamTrackSource(MediaStreamTrack mediaStreamTrack);
+    // Bug 1324548: MediaStreamTrackAudioSourceNode createMediaStreamTrackSource (AudioMediaStreamTrack mediaStreamTrack);
 
     [NewObject, Throws]
     MediaStreamAudioDestinationNode createMediaStreamDestination();
 };
deleted file mode 100644
--- a/dom/webidl/MediaStreamTrackAudioSourceNode.webidl
+++ /dev/null
@@ -1,24 +0,0 @@
-/* -*- Mode: IDL; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
-/* This Source Code Form is subject to the terms of the Mozilla Public
- * License, v. 2.0. If a copy of the MPL was not distributed with this file,
- * You can obtain one at http://mozilla.org/MPL/2.0/.
- *
- * The origin of this IDL file is
- * https://webaudio.github.io/web-audio-api/
- *
- * Copyright © 2012 W3C® (MIT, ERCIM, Keio), All Rights Reserved. W3C
- * liability, trademark and document use rules apply.
- */
-
-dictionary MediaStreamTrackAudioSourceOptions {
-    required MediaStreamTrack mediaStreamTrack;
-};
-
-[Pref="dom.webaudio.enabled",
- Constructor(AudioContext context, MediaStreamTrackAudioSourceOptions options)]
-interface MediaStreamTrackAudioSourceNode : AudioNode {
-
-};
-
-// Mozilla extensions
-MediaStreamTrackAudioSourceNode implements AudioNodePassThrough;
--- a/dom/webidl/moz.build
+++ b/dom/webidl/moz.build
@@ -173,19 +173,16 @@ with Files("MediaDevice*"):
     BUG_COMPONENT = ("Core", "WebRTC")
 
 with Files("Media*Source*"):
     BUG_COMPONENT = ("Core", "Web Audio")
 
 with Files("MediaStream*"):
     BUG_COMPONENT = ("Core", "WebRTC")
 
-with Files("MediaStreamTrackAudio*"):
-    BUG_COMPONENT = ("Core", "Web Audio")
-
 with Files("MediaStreamAudio*"):
     BUG_COMPONENT = ("Core", "Web Audio")
 
 with Files("MediaEncryptedEvent.webidl"):
     BUG_COMPONENT = ("Core", "Audio/Video")
 
 with Files("MediaKey*"):
     BUG_COMPONENT = ("Core", "Audio/Video: Playback")
@@ -655,17 +652,16 @@ WEBIDL_FILES = [
     'MediaQueryList.webidl',
     'MediaRecorder.webidl',
     'MediaSource.webidl',
     'MediaStream.webidl',
     'MediaStreamAudioDestinationNode.webidl',
     'MediaStreamAudioSourceNode.webidl',
     'MediaStreamError.webidl',
     'MediaStreamTrack.webidl',
-    'MediaStreamTrackAudioSourceNode.webidl',
     'MediaTrackConstraintSet.webidl',
     'MediaTrackSettings.webidl',
     'MediaTrackSupportedConstraints.webidl',
     'MerchantValidationEvent.webidl',
     'MessageChannel.webidl',
     'MessageEvent.webidl',
     'MessagePort.webidl',
     'MIDIAccess.webidl',