]> git.sesse.net Git - vlc/blobdiff - modules/audio_output/file.c
Fix wrong size given to memset (found by coccinelle static analyzer).
[vlc] / modules / audio_output / file.c
index 79e968508d04f36f869eb06ffbdd121440776c65..3bee0ebd7136c6f529b67396f9c880d391111d05 100644 (file)
@@ -34,7 +34,7 @@
 #include <vlc_plugin.h>
 #include <vlc_aout.h>
 #include <vlc_codecs.h> /* WAVEHEADER */
-#include <vlc_charset.h>
+#include <vlc_fs.h>
 
 #define FRAME_SIZE 2048
 #define A52_FRAME_NB 1536
@@ -154,7 +154,7 @@ static int Open( vlc_object_t * p_this )
     if( !strcmp( psz_name, "-" ) )
         p_aout->output.p_sys->p_file = stdout;
     else
-        p_aout->output.p_sys->p_file = utf8_fopen( psz_name, "wb" );
+        p_aout->output.p_sys->p_file = vlc_fopen( psz_name, "wb" );
 
     free( psz_name );
     if ( p_aout->output.p_sys->p_file == NULL )
@@ -221,7 +221,7 @@ static int Open( vlc_object_t * p_this )
         /* Write wave header */
         WAVEHEADER *wh = &p_aout->output.p_sys->waveh;
 
-        memset( wh, 0, sizeof(wh) );
+        memset( wh, 0, sizeof(*wh) );
 
         switch( p_aout->output.output.i_format )
         {