Backed out changeset 9173dcf026ee (bug 882567) because of mochitest-1 timeouts on Linux
authorEhsan Akhgari <ehsan@mozilla.com>
Tue, 18 Jun 2013 23:16:05 -0400
changeset 147038 822b350df442906777ba953ba8ef25738ffb05b8
parent 147037 2e1acd3b9ce881c96c0742bad38ce83ae2c02342
child 147039 1d4c00e49f937eb7ce75bdc5f90821a5e8a71dfe
push id2697
push userbbajaj@mozilla.com
push dateMon, 05 Aug 2013 18:49:53 +0000
treeherdermozilla-beta@dfec938c7b63 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
bugs882567
milestone24.0a1
backs out9173dcf026eeea673ee03428702a3f52e4d1c17d
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 changeset 9173dcf026ee (bug 882567) because of mochitest-1 timeouts on Linux Landed on a CLOSED TREE
content/media/gstreamer/GStreamerFunctionList.h
content/media/gstreamer/GStreamerReader.cpp
content/media/gstreamer/GStreamerReader.h
--- a/content/media/gstreamer/GStreamerFunctionList.h
+++ b/content/media/gstreamer/GStreamerFunctionList.h
@@ -21,17 +21,16 @@ GST_FUNC(LIBGSTAPP, gst_app_src_set_size
 GST_FUNC(LIBGSTAPP, gst_app_src_set_stream_type)
 GST_FUNC(LIBGSTREAMER, gst_bin_get_by_name)
 GST_FUNC(LIBGSTREAMER, gst_bin_get_type)
 GST_FUNC(LIBGSTREAMER, gst_bin_iterate_recurse)
 GST_FUNC(LIBGSTREAMER, gst_buffer_copy_metadata)
 GST_FUNC(LIBGSTREAMER, gst_buffer_get_type)
 GST_FUNC(LIBGSTREAMER, gst_buffer_new)
 GST_FUNC(LIBGSTREAMER, gst_buffer_new_and_alloc)
-GST_FUNC(LIBGSTREAMER, gst_bus_set_sync_handler)
 GST_FUNC(LIBGSTREAMER, gst_bus_timed_pop_filtered)
 GST_FUNC(LIBGSTREAMER, gst_caps_append)
 GST_FUNC(LIBGSTREAMER, gst_caps_can_intersect)
 GST_FUNC(LIBGSTREAMER, gst_caps_from_string)
 GST_FUNC(LIBGSTREAMER, gst_caps_get_size)
 GST_FUNC(LIBGSTREAMER, gst_caps_get_structure)
 GST_FUNC(LIBGSTREAMER, gst_caps_new_any)
 GST_FUNC(LIBGSTREAMER, gst_caps_new_empty)
@@ -50,17 +49,16 @@ GST_FUNC(LIBGSTREAMER, gst_element_query
 GST_FUNC(LIBGSTREAMER, gst_element_seek_simple)
 GST_FUNC(LIBGSTREAMER, gst_element_set_state)
 GST_FUNC(LIBGSTREAMER, gst_event_parse_new_segment)
 GST_FUNC(LIBGSTREAMER, gst_flow_get_name)
 GST_FUNC(LIBGSTREAMER, gst_init)
 GST_FUNC(LIBGSTREAMER, gst_init_check)
 GST_FUNC(LIBGSTREAMER, gst_iterator_next)
 GST_FUNC(LIBGSTREAMER, gst_message_parse_error)
-GST_FUNC(LIBGSTREAMER, gst_message_type_get_name)
 GST_FUNC(LIBGSTREAMER, gst_mini_object_get_type)
 GST_FUNC(LIBGSTREAMER, gst_mini_object_new)
 GST_FUNC(LIBGSTREAMER, gst_mini_object_ref)
 GST_FUNC(LIBGSTREAMER, gst_mini_object_unref)
 GST_FUNC(LIBGSTREAMER, gst_object_get_parent)
 GST_FUNC(LIBGSTREAMER, gst_object_unref)
 GST_FUNC(LIBGSTREAMER, gst_pad_add_event_probe)
 GST_FUNC(LIBGSTREAMER, gst_pad_alloc_buffer)
--- a/content/media/gstreamer/GStreamerReader.cpp
+++ b/content/media/gstreamer/GStreamerReader.cpp
@@ -173,32 +173,16 @@ nsresult GStreamerReader::Init(MediaDeco
                nullptr);
 
   g_signal_connect(G_OBJECT(mPlayBin), "notify::source",
                    G_CALLBACK(GStreamerReader::PlayBinSourceSetupCb), this);
 
   return NS_OK;
 }
 
-GstBusSyncReply
-GStreamerReader::ErrorCb(GstBus *aBus, GstMessage *aMessage, gpointer aUserData)
-{
-  return static_cast<GStreamerReader*>(aUserData)->Error(aBus, aMessage);
-}
-
-GstBusSyncReply
-GStreamerReader::Error(GstBus *aBus, GstMessage *aMessage)
-{
-  if (GST_MESSAGE_TYPE(aMessage) == GST_MESSAGE_ERROR) {
-    Eos();
-  }
-
-  return GST_BUS_PASS;
-}
-
 void GStreamerReader::PlayBinSourceSetupCb(GstElement* aPlayBin,
                                            GParamSpec* pspec,
                                            gpointer aUserData)
 {
   GstElement *source;
   GStreamerReader* reader = reinterpret_cast<GStreamerReader*>(aUserData);
 
   g_object_get(aPlayBin, "source", &source, NULL);
@@ -358,19 +342,16 @@ nsresult GStreamerReader::ReadMetadata(V
   g_object_get(mPlayBin, "n-video", &n_video, "n-audio", &n_audio, nullptr);
   mInfo.mHasVideo = n_video != 0;
   mInfo.mHasAudio = n_audio != 0;
 
   *aInfo = mInfo;
 
   *aTags = nullptr;
 
-  // Watch the pipeline for fatal errors
-  gst_bus_set_sync_handler(mBus, GStreamerReader::ErrorCb, this);
-
   /* set the pipeline to PLAYING so that it starts decoding and queueing data in
    * the appsinks */
   gst_element_set_state(mPlayBin, GST_STATE_PLAYING);
 
   return NS_OK;
 }
 
 nsresult GStreamerReader::CheckSupportedFormats()
@@ -1018,20 +999,20 @@ void GStreamerReader::NewAudioBuffer()
    */
   mAudioSinkBufferCount++;
   mon.NotifyAll();
 }
 
 void GStreamerReader::EosCb(GstAppSink* aSink, gpointer aUserData)
 {
   GStreamerReader* reader = reinterpret_cast<GStreamerReader*>(aUserData);
-  reader->Eos();
+  reader->Eos(aSink);
 }
 
-void GStreamerReader::Eos()
+void GStreamerReader::Eos(GstAppSink* aSink)
 {
   /* We reached the end of the stream */
   {
     ReentrantMonitorAutoEnter mon(mGstThreadsMonitor);
     /* Potentially unblock DecodeVideoFrame and DecodeAudioData */
     mReachedEos = true;
     mon.NotifyAll();
   }
--- a/content/media/gstreamer/GStreamerReader.h
+++ b/content/media/gstreamer/GStreamerReader.h
@@ -59,19 +59,16 @@ private:
 
   /* Called once the pipeline is setup to check that the stream only contains
    * supported formats
    */
   nsresult CheckSupportedFormats();
 
   /* Gst callbacks */
 
-  static GstBusSyncReply ErrorCb(GstBus *aBus, GstMessage *aMessage, gpointer aUserData);
-  GstBusSyncReply Error(GstBus *aBus, GstMessage *aMessage);
-
   /* Called on the source-setup signal emitted by playbin. Used to
    * configure appsrc .
    */
   static void PlayBinSourceSetupCb(GstElement* aPlayBin,
                                    GParamSpec* pspec,
                                    gpointer aUserData);
   void PlayBinSourceSetup(GstAppSrc* aSource);
 
@@ -114,17 +111,17 @@ private:
 
   /* Called when buffers reach the sinks */
   static GstFlowReturn NewBufferCb(GstAppSink* aSink, gpointer aUserData);
   void NewVideoBuffer();
   void NewAudioBuffer();
 
   /* Called at end of stream, when decoding has finished */
   static void EosCb(GstAppSink* aSink, gpointer aUserData);
-  void Eos();
+  void Eos(GstAppSink* aSink);
 
   GstElement* mPlayBin;
   GstBus* mBus;
   GstAppSrc* mSource;
   /* video sink bin */
   GstElement* mVideoSink;
   /* the actual video app sink */
   GstAppSink* mVideoAppSink;