[vlc-devel] [PATCH] text_style: fix text_segment_Copy() when there's no next segment

Steve Lhomme robux4 at gmail.com
Thu Sep 10 13:39:19 CEST 2015


---
 src/misc/text_style.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/misc/text_style.c b/src/misc/text_style.c
index eddddfe..a52273d 100644
--- a/src/misc/text_style.c
+++ b/src/misc/text_style.c
@@ -206,7 +206,7 @@ text_segment_t *text_segment_Copy( text_segment_t *p_src )
 {
     text_segment_t *p_dst = NULL, *p_dst0 = NULL;
 
-    while( p_src && p_src->p_next ) {
+    while( p_src ) {
         text_segment_t *p_next = text_segment_New( p_src->psz_text );
         if( p_next )
             p_next->style = text_style_Duplicate( p_src->style );
-- 
2.5.0



More information about the vlc-devel mailing list