[GStreamer] No need to assert the pipeline's bus presence in MediaPlayerPrivateGStrea...
authorzandobersek@gmail.com <zandobersek@gmail.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 23 Nov 2015 13:38:49 +0000 (13:38 +0000)
committerzandobersek@gmail.com <zandobersek@gmail.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 23 Nov 2015 13:38:49 +0000 (13:38 +0000)
https://bugs.webkit.org/show_bug.cgi?id=151558

Reviewed by Carlos Garcia Campos.

In the MediaPlayerPrivateGStreamerBase destructor, there's some leftover code
that acquires a reference to the GStreamer pipeline's bus object and then
just asserts that it's not null. Not very useful, so remove it.

Also use nullptr to null out the m_player member.

* platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp:
(WebCore::MediaPlayerPrivateGStreamerBase::~MediaPlayerPrivateGStreamerBase):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@192744 268f45cc-cd09-0410-ab3c-d52691b4dbfc

Source/WebCore/ChangeLog
Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp

index 3269c64..a4a2247 100644 (file)
@@ -1,3 +1,19 @@
+2015-11-23  Zan Dobersek  <zdobersek@igalia.com>
+
+        [GStreamer] No need to assert the pipeline's bus presence in MediaPlayerPrivateGStreamerBase dtor
+        https://bugs.webkit.org/show_bug.cgi?id=151558
+
+        Reviewed by Carlos Garcia Campos.
+
+        In the MediaPlayerPrivateGStreamerBase destructor, there's some leftover code
+        that acquires a reference to the GStreamer pipeline's bus object and then
+        just asserts that it's not null. Not very useful, so remove it.
+
+        Also use nullptr to null out the m_player member.
+
+        * platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp:
+        (WebCore::MediaPlayerPrivateGStreamerBase::~MediaPlayerPrivateGStreamerBase):
+
 2015-11-17  Sergio Villar Senin  <svillar@igalia.com>
 
         ASSERTION FAILED: freeSpace >= 0 in WebCore::RenderGrid::computeTrackSizesForDirection
index eded29b..201707f 100644 (file)
@@ -123,16 +123,10 @@ MediaPlayerPrivateGStreamerBase::~MediaPlayerPrivateGStreamerBase()
 
     g_mutex_clear(&m_sampleMutex);
 
-    m_player = 0;
+    m_player = nullptr;
 
     g_signal_handlers_disconnect_matched(m_volumeElement.get(), G_SIGNAL_MATCH_DATA, 0, 0, nullptr, nullptr, this);
 
-    if (m_pipeline) {
-        GRefPtr<GstBus> bus = adoptGRef(gst_pipeline_get_bus(GST_PIPELINE(m_pipeline.get())));
-        ASSERT(bus);
-        m_pipeline.clear();
-    }
-
 #if USE(TEXTURE_MAPPER_GL) && !USE(COORDINATED_GRAPHICS)
     if (client())
         client()->platformLayerWillBeDestroyed();