- if( i_outsize > p_out_buf->i_buffer ) {
-#if 0 /* FIXME: This requires audio filter2 to work */
- p_out_buf = block_Realloc( p_out_buf, i_outsize, 0 );
- if( p_out_buf == NULL )
- abort();
-#else /* This fails horribly if we have more than two buffers in the
- * pipeline, or if the buffer is passed to another thread... XXX */
- void *temp = realloc( p->p_buffers[ p->i_buf ], i_outsize );
- if( temp == NULL )
- {
- return;
- }
- p->p_buffers[ p->i_buf ] = temp;
- p_out_buf->p_buffer = p->p_buffers[ p->i_buf ];
- p->i_buf = ! p->i_buf;
-#endif
- }
+ block_t *p_out_buf = filter_NewAudioBuffer( p_filter, i_outsize );
+ if( p_out_buf == NULL )
+ return NULL;