gnonlin: gnlfilesource: use gst_filename_to_uri() to create a proper file URI

Tim Müller tpm at kemper.freedesktop.org
Fri Jan 13 04:33:21 PST 2012


Module: gnonlin
Branch: master
Commit: 49e185c5720b747e84dd2d36d24a2a2efec14d19
URL:    http://cgit.freedesktop.org/gstreamer/gnonlin/commit/?id=49e185c5720b747e84dd2d36d24a2a2efec14d19

Author: Tim-Philipp Müller <tim.muller at collabora.co.uk>
Date:   Fri Jan 13 12:18:14 2012 +0000

gnlfilesource: use gst_filename_to_uri() to create a proper file URI

This will create a correct URI even for relative paths, which are
allowed for "location" properties.

Bump GStreamer core/base requirement to 0.10.33 for that API.

---

 configure.ac        |    4 ++--
 gnl/gnlfilesource.c |    2 +-
 2 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/configure.ac b/configure.ac
index 9ca0667..b8ebbb9 100644
--- a/configure.ac
+++ b/configure.ac
@@ -45,8 +45,8 @@ AC_LIBTOOL_WIN32_DLL
 AM_PROG_LIBTOOL
 
 dnl *** required versions of GStreamer stuff ***
-GST_REQ=0.10.30
-GSTPB_REQ=0.10.30
+GST_REQ=0.10.33
+GSTPB_REQ=0.10.33
 
 dnl *** autotools stuff ****
 
diff --git a/gnl/gnlfilesource.c b/gnl/gnlfilesource.c
index 84238aa..688a1a5 100644
--- a/gnl/gnlfilesource.c
+++ b/gnl/gnlfilesource.c
@@ -109,7 +109,7 @@ gnl_filesource_set_location (GnlFileSource * fs, const gchar * location)
   GST_DEBUG_OBJECT (fs, "location: '%s'", location);
 
   if (g_ascii_strncasecmp (location, "file://", 7))
-    tmp = g_strdup_printf ("file://%s", location);
+    tmp = gst_filename_to_uri (location, NULL);
   else
     tmp = g_strdup (location);
   GST_DEBUG ("%s", tmp);



More information about the gstreamer-commits mailing list