{
int line = 0;
QGridLayout *l = new QGridLayout( this );
+ p_input = NULL;
#define ADD_META( string, widget ) { \
l->addWidget( new QLabel( qtr( string ) + " :" ), line, 0 ); \
meta_export_t p_export;
p_export.p_item = p_input;
+ if( p_input == NULL )
+ return;
+
/* we can write meta data only in a file */
if( ( p_input->i_type == ITEM_TYPE_AFILE ) || \
( p_input->i_type == ITEM_TYPE_VFILE ) )
playlist_t *p_playlist = (playlist_t *)p_this;
meta_export_t *p_export = (meta_export_t *)p_playlist->p_private;
input_item_t *p_item = p_export->p_item;
+
+ if( p_item == NULL )
+ {
+ msg_Err( p_this, "Can't save meta data of an empty input" );
+ return VLC_EGENERIC;
+ }
TagLib::FileRef f( p_export->psz_file );
if( !f.isNull() && f.tag() )
{
+ msg_Dbg( p_this, "Updating metadata for %s", p_export->psz_file );
TagLib::Tag *tag = f.tag();
SET( Artist, p_item->p_meta->psz_artist );
if( p_item->p_meta->psz_title )