[vlc-devel] [PATCH] LUA: Remove protocol from vlc.path after redirect

Gaurav Narula gnarula94 at gmail.com
Thu Jan 5 16:44:53 CET 2012


---
 modules/access/http.c |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/modules/access/http.c b/modules/access/http.c
index d32a0a9..ed42c25 100644
--- a/modules/access/http.c
+++ b/modules/access/http.c
@@ -581,7 +581,8 @@ connect:
             goto error;
         }
         free( p_access->psz_location );
-        p_access->psz_location = strdup( p_sys->psz_location );
+        char *slash = strstr(p_sys->psz_location, "://") + 3;
+        p_access->psz_location = strdup( slash );
         /* Clean up current Open() run */
         vlc_UrlClean( &p_sys->url );
         http_auth_Reset( &p_sys->auth );
-- 
1.7.1




More information about the vlc-devel mailing list