Commit 02fbd587 authored by Damien Fouilleul's avatar Damien Fouilleul

wxwidgets: fix crash in playlist due to change in meta behaviour (all metas...

wxwidgets: fix crash in playlist due to change in meta behaviour (all metas used to retunr "" rather than NULL)
parent 5ccbc289
...@@ -525,7 +525,7 @@ void Playlist::UpdateTreeItem( wxTreeItemId item ) ...@@ -525,7 +525,7 @@ void Playlist::UpdateTreeItem( wxTreeItemId item )
wxU( " )" ) ); wxU( " )" ) );
} }
if( !strcmp( psz_artist, "" ) || p_item->p_input->b_fixed_name == VLC_TRUE ) if( !psz_artist || !strcmp( psz_artist, "" ) || p_item->p_input->b_fixed_name == VLC_TRUE )
{ {
msg = wxString( wxU( psz_name ) ) + duration; msg = wxString( wxU( psz_name ) ) + duration;
} }
...@@ -534,6 +534,7 @@ void Playlist::UpdateTreeItem( wxTreeItemId item ) ...@@ -534,6 +534,7 @@ void Playlist::UpdateTreeItem( wxTreeItemId item )
msg = wxString(wxU( psz_artist )) + wxT(" - ") + msg = wxString(wxU( psz_artist )) + wxT(" - ") +
wxString(wxU(psz_name)) + duration; wxString(wxU(psz_name)) + duration;
} }
if( psz_artist )
free( psz_artist ); free( psz_artist );
free( psz_name ); free( psz_name );
treectrl->SetItemText( item , msg ); treectrl->SetItemText( item , msg );
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment