Commit b9dc1b7d authored by Felix Paul Kühne's avatar Felix Paul Kühne

macosx/playlist: add missing error handling

(cherry picked from commit 5feeba277311d1d3215016dc7ce1e17e79c922f1)
parent efbf668d
......@@ -1106,15 +1106,14 @@
o_one_item = [o_array objectAtIndex: i_item];
p_input = [self createItem: o_one_item];
if( !p_input )
{
continue;
}
/* Add the item */
/* FIXME: playlist_AddInput() can fail */
playlist_AddInput( p_playlist, p_input, PLAYLIST_INSERT, i_position == -1 ? PLAYLIST_END : i_position + i_item, b_usingPlaylist,
pl_Locked );
int returnValue = playlist_AddInput( p_playlist, p_input, PLAYLIST_INSERT, i_position == -1 ? PLAYLIST_END : i_position + i_item, b_usingPlaylist, pl_Locked );
if (returnValue != VLC_SUCCESS) {
vlc_gc_decref( p_input );
continue;
}
if( i_item == 0 && !b_enqueue )
{
......
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