[vlc-commits] codec: subsusf: use video_format_Init/Clean

Francois Cartegnie git at videolan.org
Mon Nov 21 21:23:04 CET 2016


vlc | branch: master | Francois Cartegnie <fcvlcdev at free.fr> | Mon Nov 21 20:48:33 2016 +0100| [6babd6d345df7b4a8debb9919d6c0148a1b95abf] | committer: Francois Cartegnie

codec: subsusf: use video_format_Init/Clean

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

 modules/codec/subsusf.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/modules/codec/subsusf.c b/modules/codec/subsusf.c
index cc8814e..361cae3 100644
--- a/modules/codec/subsusf.c
+++ b/modules/codec/subsusf.c
@@ -423,11 +423,11 @@ static subpicture_region_t *CreateTextRegion( decoder_t *p_dec,
     VLC_UNUSED( i_len );
 
     /* Create a new subpicture region */
-    memset( &fmt, 0, sizeof(video_format_t) );
-    fmt.i_chroma = VLC_CODEC_TEXT;
+    video_format_Init( &fmt, VLC_CODEC_TEXT );
     fmt.i_width = fmt.i_height = 0;
     fmt.i_x_offset = fmt.i_y_offset = 0;
     p_text_region = subpicture_region_New( &fmt );
+    video_format_Clean( &fmt );
 
     if( p_text_region != NULL )
     {



More information about the vlc-commits mailing list