]> git.sesse.net Git - vlc/commitdiff
* rss.c: Test fix for a bug i can't reproduce (most likely due to a missing 0 at...
authorAntoine Cellerier <dionoea@videolan.org>
Wed, 9 May 2007 20:20:52 +0000 (20:20 +0000)
committerAntoine Cellerier <dionoea@videolan.org>
Wed, 9 May 2007 20:20:52 +0000 (20:20 +0000)
modules/video_filter/rss.c

index db0d0af59d1380b12deb1a0136c0db18937ee481..2ee7e89dcbb3ca48624542fd632fc96d5a9b9736 100644 (file)
@@ -256,7 +256,8 @@ static int CreateFilter( vlc_object_t *p_this )
     p_sys->i_length = var_CreateGetInteger( p_filter, CFG_PREFIX "length" );
     p_sys->i_ttl = __MAX( 0, var_CreateGetInteger( p_filter, CFG_PREFIX "ttl" ) );
     p_sys->b_images = var_CreateGetBool( p_filter, CFG_PREFIX "images" );
-    p_sys->psz_marquee = (char *)malloc( p_sys->i_length );
+    p_sys->psz_marquee = (char *)malloc( p_sys->i_length + 1 );
+    p_sys->psz_marquee[p_sys->i_length] = '\0';
 
     p_sys->p_style = malloc( sizeof( text_style_t ));
     memcpy( p_sys->p_style, &default_text_style, sizeof( text_style_t ));