]> git.sesse.net Git - vlc/blobdiff - modules/codec/faad.c
Use calloc when applicable (decoders).
[vlc] / modules / codec / faad.c
index fd5636efbf8a4109d8510952f420aa0c2835c5fe..022106dad5b59fb4e15c6b4c451cacae2b50a40c 100644 (file)
@@ -123,8 +123,7 @@ static int Open( vlc_object_t *p_this )
     }
 
     /* Allocate the memory needed to store the decoder's structure */
-    if( ( p_dec->p_sys = p_sys =
-          (decoder_sys_t *)malloc(sizeof(decoder_sys_t)) ) == NULL )
+    if( ( p_dec->p_sys = p_sys = malloc( sizeof(*p_sys) ) ) == NULL )
         return VLC_ENOMEM;
 
     /* Open a faad context */