[vlc-devel] [vlc-commits] libvlc: media_list_player: Fix invalid subitem detection
Hugo Beauzée-Luyssen
hugo at beauzee.fr
Mon Mar 19 15:06:21 CET 2018
On Mon, Mar 19, 2018, at 2:54 PM, Hugo Beauzée-Luyssen wrote:
> vlc | branch: master | Hugo Beauzée-Luyssen <hugo at beauzee.fr> | Mon Mar
> 19 14:41:28 2018 +0100| [ceb3ba9ce299491f4150f69834dd33bf08866a06] |
> committer: Hugo Beauzée-Luyssen
>
> libvlc: media_list_player: Fix invalid subitem detection
>
> Fix #19939
>
> > http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=ceb3ba9ce299491f4150f69834dd33bf08866a06
> ---
>
> lib/media_list_player.c | 3 ++-
> 1 file changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/lib/media_list_player.c b/lib/media_list_player.c
> index d73415b1b3..5161428df2 100644
> --- a/lib/media_list_player.c
> +++ b/lib/media_list_player.c
> @@ -160,7 +160,8 @@ get_next_path(libvlc_media_list_player_t * p_mlp,
> bool b_loop)
> if (p_sublist_of_playing_item)
> {
> libvlc_media_list_release(p_sublist_of_playing_item);
> - return libvlc_media_list_path_copy_by_appending(p_mlp-
> >current_playing_item_path, 0);
> + if (libvlc_media_list_count(p_sublist_of_playing_item) > 0)
> + return libvlc_media_list_path_copy_by_appending(p_mlp-
> >current_playing_item_path, 0);
Hm. Obvious potential use after free should have been obvious. I'll push force over this, sorry
> }
>
> /* Try to catch parent element */
>
> _______________________________________________
> vlc-commits mailing list
> vlc-commits at videolan.org
> https://mailman.videolan.org/listinfo/vlc-commits
--
Hugo Beauzée-Luyssen
hugo at beauzee.fr
More information about the vlc-devel
mailing list