]> git.sesse.net Git - vlc/blobdiff - modules/audio_filter/converter/a52tofloat32.c
Removes trailing spaces. Removes tabs.
[vlc] / modules / audio_filter / converter / a52tofloat32.c
index 400bbd98ec5a3bba1cf0c7124692bec2b2a01527..6cac68dd3ab219b0e799664cf48489152bf95511 100644 (file)
@@ -29,8 +29,6 @@
  *****************************************************************************/
 #include <vlc/vlc.h>
 
-#include <stdlib.h>                                      /* malloc(), free() */
-#include <string.h>                                              /* strdup() */
 #ifdef HAVE_STDINT_H
 #   include <stdint.h>                                         /* int16_t .. */
 #elif HAVE_INTTYPES_H
 #   include "a52dec/a52.h"
 #endif
 
-#include <vlc/decoder.h>
-#include "aout_internal.h"
-#include "vlc_filter.h"
+#include <vlc_aout.h>
+#include <vlc_block.h>
+#include <vlc_filter.h>
 
 /*****************************************************************************
  * Local prototypes
  *****************************************************************************/
 static int  Create    ( vlc_object_t * );
 static void Destroy   ( vlc_object_t * );
-static void DoWork    ( aout_instance_t *, aout_filter_t *, aout_buffer_t *,  
+static void DoWork    ( aout_instance_t *, aout_filter_t *, aout_buffer_t *,
                         aout_buffer_t * );
 static int  Open      ( vlc_object_t *, filter_sys_t *,
                         audio_format_t, audio_format_t );
@@ -161,7 +159,7 @@ static int Create( vlc_object_t *p_this )
 }
 
 /*****************************************************************************
- * Open: 
+ * Open:
  *****************************************************************************/
 static int Open( vlc_object_t *p_this, filter_sys_t *p_sys,
                  audio_format_t input, audio_format_t output )
@@ -379,7 +377,7 @@ static void DoWork( aout_instance_t * p_aout, aout_filter_t * p_filter,
         if ( ((p_sys->i_flags & A52_CHANNEL_MASK) == A52_CHANNEL1
                || (p_sys->i_flags & A52_CHANNEL_MASK) == A52_CHANNEL2
                || (p_sys->i_flags & A52_CHANNEL_MASK) == A52_MONO)
-              && (p_filter->output.i_physical_channels 
+              && (p_filter->output.i_physical_channels
                    & (AOUT_CHAN_LEFT | AOUT_CHAN_RIGHT)) )
         {
             Duplicate( (float *)(p_out_buf->p_buffer + i * i_bytes_per_block),
@@ -416,7 +414,7 @@ static void Destroy( vlc_object_t *p_this )
 }
 
 /*****************************************************************************
- * OpenFilter: 
+ * OpenFilter:
  *****************************************************************************/
 static int OpenFilter( vlc_object_t *p_this )
 {
@@ -436,14 +434,6 @@ static int OpenFilter( vlc_object_t *p_this )
         p_filter->fmt_out.i_codec = VLC_FOURCC('f','l','3','2');
 #endif
 
-    /* Allocate the memory needed to store the module's structure */
-    p_sys = p_filter->p_sys = malloc( sizeof(filter_sys_t) );
-    if( p_sys == NULL )
-    {
-        msg_Err( p_filter, "out of memory" );
-        return VLC_EGENERIC;
-    }
-
     /* Allocate the memory needed to store the module's structure */
     p_filter->p_sys = p_sys = malloc( sizeof(filter_sys_t) );
     if( p_sys == NULL )