Title: [294635] releases/WebKitGTK/webkit-2.36/Source/WebCore
Revision
294635
Author
[email protected]
Date
2022-05-23 06:23:56 -0700 (Mon, 23 May 2022)

Log Message

Merge r293319 - [GStreamer] Disable new demuxers based on adaptivedemux2
https://bugs.webkit.org/show_bug.cgi?id=239701

Patch by Philippe Normand <[email protected]> on 2022-04-25
Reviewed by Xabier Rodriguez-Calvar.

The new demuxers based on adaptivedemux2 cannot be used in WebKit yet because this new base
class does not abstract away network access. They can't work in a sandboxed media process,
so demote their rank in order to prevent decodebin3 from auto-plugging them.

* platform/graphics/gstreamer/GStreamerCommon.cpp:
(WebCore::registerWebKitGStreamerElements):

Canonical link: https://commits.webkit.org/249942@main

Modified Paths

Diff

Modified: releases/WebKitGTK/webkit-2.36/Source/WebCore/ChangeLog (294634 => 294635)


--- releases/WebKitGTK/webkit-2.36/Source/WebCore/ChangeLog	2022-05-23 13:14:14 UTC (rev 294634)
+++ releases/WebKitGTK/webkit-2.36/Source/WebCore/ChangeLog	2022-05-23 13:23:56 UTC (rev 294635)
@@ -1,3 +1,17 @@
+2022-04-24  Philippe Normand  <[email protected]>
+
+        [GStreamer] Disable new demuxers based on adaptivedemux2
+        https://bugs.webkit.org/show_bug.cgi?id=239701
+
+        Reviewed by Xabier Rodriguez-Calvar.
+
+        The new demuxers based on adaptivedemux2 cannot be used in WebKit yet because this new base
+        class does not abstract away network access. They can't work in a sandboxed media process,
+        so demote their rank in order to prevent decodebin3 from auto-plugging them.
+
+        * platform/graphics/gstreamer/GStreamerCommon.cpp:
+        (WebCore::registerWebKitGStreamerElements):
+
 2022-05-16  Loïc Le Page  <[email protected]>
 
         REGRESSION(r294104): [GStreamer][VideoCapture] Webcam raw streams may hang up the video capture pipeline

Modified: releases/WebKitGTK/webkit-2.36/Source/WebCore/platform/graphics/gstreamer/GStreamerCommon.cpp (294634 => 294635)


--- releases/WebKitGTK/webkit-2.36/Source/WebCore/platform/graphics/gstreamer/GStreamerCommon.cpp	2022-05-23 13:14:14 UTC (rev 294634)
+++ releases/WebKitGTK/webkit-2.36/Source/WebCore/platform/graphics/gstreamer/GStreamerCommon.cpp	2022-05-23 13:23:56 UTC (rev 294635)
@@ -356,6 +356,17 @@
                     gst_plugin_feature_set_rank(GST_PLUGIN_FEATURE_CAST(avAACDecoderFactory.get()), GST_RANK_MARGINAL);
             }
         }
+
+        // The new demuxers based on adaptivedemux2 cannot be used in WebKit yet because this new
+        // base class does not abstract away network access. They can't work in a sandboxed
+        // media process, so demote their rank in order to prevent decodebin3 from auto-plugging them.
+        if (webkitGstCheckVersion(1, 21, 0)) {
+            const char* const elementNames[] = { "dashdemux2", "hlsdemux2", "mssdemux2" };
+            for (unsigned i = 0; i < G_N_ELEMENTS(elementNames); i++) {
+                if (auto factory = adoptGRef(gst_element_factory_find(elementNames[i])))
+                    gst_plugin_feature_set_rank(GST_PLUGIN_FEATURE_CAST(factory.get()), GST_RANK_NONE);
+            }
+        }
     });
 }
 
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to