/*****************************************************************************
* Preamble
*****************************************************************************/
+#ifdef HAVE_CONFIG_H
+# include "config.h"
+#endif
+
#include <vlc/vlc.h>
#include <stdlib.h> /* free() */
if( ( p_vout->fmt_render.i_width != p_fmt->i_width ) ||
( p_vout->fmt_render.i_height != p_fmt->i_height ) ||
- ( p_vout->fmt_render.i_chroma != p_fmt->i_chroma ) ||
( p_vout->fmt_render.i_aspect != p_fmt->i_aspect ) ||
p_vout->b_filter_change )
{
p_vout->p_cfg = p_cfg;
p_vout->p_module = module_Need( p_vout,
( p_vout->psz_filter_chain && *p_vout->psz_filter_chain ) ?
- "video filter" : "video output", psz_name, 0 );
+ "video filter" : "video output", psz_name, p_vout->psz_filter_chain && *p_vout->psz_filter_chain );
free( psz_name );
if( p_vout->p_module == NULL )
char *psz_artist = input_item_GetArtist( input_GetItem( p_input ) );
char *psz_name = input_item_GetTitle( input_GetItem( p_input ) );
if( EMPTY_STR( psz_name ) )
- {
- free( psz_name );
- psz_name = input_item_GetName( input_GetItem( p_input ) );
- }
+ {
+ free( psz_name );
+ psz_name = input_item_GetName( input_GetItem( p_input ) );
+ }
if( !EMPTY_STR( psz_nowplaying ) )
{
vout_ShowTextAbsolute( p_vout, DEFAULT_CHAN,
else if( !EMPTY_STR( psz_artist ) )
{
char *psz_string = NULL;
-
- psz_string = malloc( strlen( psz_name ) + strlen( psz_artist ) );
- if( psz_string )
+ if( asprintf( &psz_string, "%s - %s", psz_name, psz_artist ) != -1 )
{
- sprintf( psz_string, "%s - %s", psz_name, psz_artist );
-
vout_ShowTextAbsolute( p_vout, DEFAULT_CHAN,
psz_string, NULL,
p_vout->i_title_position,
free( psz_nowplaying );
}
}
+