]> git.sesse.net Git - vlc/blobdiff - modules/audio_output/file.c
threads: Make sure we don't re-create a thread if the object has already one.
[vlc] / modules / audio_output / file.c
index 0c877eb439ac5b417b306a9c92417dbc998af444..07da0fe1384492ef5aeeea22a6e2eff31fb3b626 100644 (file)
 /*****************************************************************************
  * Preamble
  *****************************************************************************/
-#include <errno.h>
 
 #ifdef HAVE_CONFIG_H
 # include "config.h"
 #endif
 
-#include <vlc/vlc.h>
+#include <errno.h>
+
+#include <vlc_common.h>
 #include <vlc_plugin.h>
 #include <vlc_aout.h>
 #include <vlc_codecs.h> /* WAVEHEADER */
@@ -154,10 +155,7 @@ static int Open( vlc_object_t * p_this )
     /* Allocate structure */
     p_aout->output.p_sys = malloc( sizeof( aout_sys_t ) );
     if( p_aout->output.p_sys == NULL )
-    {
-        msg_Err( p_aout, "out of memory" );
-        return VLC_EGENERIC;
-    }
+        return VLC_ENOMEM;
 
     if( !strcmp( psz_name, "-" ) )
         p_aout->output.p_sys->p_file = stdout;