]> git.sesse.net Git - vlc/commitdiff
Compile fix + handle case with no xml:base
authorChristophe Mutricy <xtophe@videolan.org>
Wed, 25 Oct 2006 11:53:38 +0000 (11:53 +0000)
committerChristophe Mutricy <xtophe@videolan.org>
Wed, 25 Oct 2006 11:53:38 +0000 (11:53 +0000)
modules/demux/playlist/xspf.c

index d4fe4af3c7b63fbdeba9edb6bac14ef339287a48..89dcd9a814f6a5b807ed929ec10957d1a92a80e5 100644 (file)
@@ -533,7 +533,8 @@ static vlc_bool_t parse_track_node COMPLEX_INTERFACE
 
                     if( psz_uri )
                     {
-                        if( !strstr( psz_uri, "://" ) )
+                        if( p_demux->p_sys->psz_base && 
+                            !strstr( psz_uri, "://" ) )
                         {
                            char* psz_tmp = malloc( 
                                    strlen(p_demux->p_sys->psz_base) + 
@@ -541,7 +542,7 @@ static vlc_bool_t parse_track_node COMPLEX_INTERFACE
                            if( !psz_tmp )
                            {
                                msg_Err( p_demux, "out of memory");
-                               return ENOMEM;
+                               return VLC_FALSE;
                            }
                            sprintf( psz_tmp, "%s%s", 
                                     p_demux->p_sys->psz_base, psz_uri );