[vlc-devel] commit: When we fill the name of an input item with URI parts, use decode_URI() so it becomes easier to read. (Derk-Jan Hartman )

git version control git at videolan.org
Tue Jun 23 23:15:20 CEST 2009


vlc | branch: 1.0-bugfix | Derk-Jan Hartman <hartman at videolan.org> | Tue Jun 23 23:06:47 2009 +0200| [3ab66ebedef49d1f9921eb9d5a63185fc845505b] | committer: Derk-Jan Hartman 

When we fill the name of an input item with URI parts, use decode_URI() so it becomes easier to read.

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

 src/input/item.c |    8 ++++++++
 1 files changed, 8 insertions(+), 0 deletions(-)

diff --git a/src/input/item.c b/src/input/item.c
index c82b2a0..7778ebc 100644
--- a/src/input/item.c
+++ b/src/input/item.c
@@ -366,6 +366,10 @@ void input_item_SetURI( input_item_t *p_i, const char *psz_uri )
             psz_filename++;
         if( psz_filename && *psz_filename )
             p_i->psz_name = strdup( psz_filename );
+
+        /* Make the name more readable */
+        if( p_i->psz_name )
+            decode_URI( p_i->psz_name );
     }
 
     /* The name is NULL: fill it with everything except login and password */
@@ -394,6 +398,10 @@ void input_item_SetURI( input_item_t *p_i, const char *psz_uri )
                           url.psz_path ? url.psz_path : "" );
         }
         vlc_UrlClean( &url );
+
+        /* Make the name more readable */
+        if( p_i->psz_name )
+            decode_URI( p_i->psz_name );
     }
 
     vlc_mutex_unlock( &p_i->lock );




More information about the vlc-devel mailing list