Signed-off-by: Pierre d'Herbemont <pdherbemont@free.fr>
void libvlc_media_list_player_play_item_at_index(libvlc_media_list_player_t * p_mlp, int i_index, libvlc_exception_t * p_e)
{
VLC_UNUSED(p_e);
+
+ lock(p_mlp);
set_current_playing_item(p_mlp, libvlc_media_list_path_with_root_index(i_index));
+ unlock(p_mlp);
/* Send the next item event */
libvlc_event_t event;
libvlc_exception_raise(p_e, "No such item in media list");
return;
}
+
+ lock(p_mlp);
set_current_playing_item(p_mlp, path);
+ unlock(p_mlp);
+
libvlc_media_player_play(p_mlp->p_mi, p_e);
}