[vlc-commits] access/rtp: do not probe every demuxer unless explicitly asked

Filip Roséen git at videolan.org
Fri Oct 14 16:34:43 CEST 2016


vlc | branch: master | Filip Roséen <filip at atch.se> | Fri Oct 14 16:24:59 2016 +0200| [356329a2d197864f81df8db1d9756827efee2ed4] | committer: Thomas Guillem

access/rtp: do not probe every demuxer unless explicitly asked

Signed-off-by: Thomas Guillem <thomas at gllm.fr>

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=356329a2d197864f81df8db1d9756827efee2ed4
---

 modules/access/rtp/rtp.c | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

diff --git a/modules/access/rtp/rtp.c b/modules/access/rtp/rtp.c
index be8e82a..fa117fa 100644
--- a/modules/access/rtp/rtp.c
+++ b/modules/access/rtp/rtp.c
@@ -639,7 +639,12 @@ static void mpv_decode (demux_t *demux, void *data, block_t *block)
  */
 static void *ts_init (demux_t *demux)
 {
-    return stream_init (demux, *demux->psz_demux ? demux->psz_demux : "ts");
+    char const* name = demux->psz_demux;
+
+    if (*name == '\0' || !strcasecmp(name, "any"))
+        name = NULL;
+
+    return stream_init (demux, name ? name : "ts");
 }
 
 



More information about the vlc-commits mailing list