diff options
-rw-r--r-- | mpvcore/player/loadfile.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/mpvcore/player/loadfile.c b/mpvcore/player/loadfile.c index 876994ac93..d6347e24c1 100644 --- a/mpvcore/player/loadfile.c +++ b/mpvcore/player/loadfile.c @@ -894,8 +894,9 @@ static void print_resolve_contents(struct mp_log *log, // from the given playlist pl, so the entries don't actually need to be copied. static void transfer_playlist(struct MPContext *mpctx, struct playlist *pl) { - if (mpctx->demuxer->playlist->first) { - playlist_transfer_entries(mpctx->playlist, mpctx->demuxer->playlist); + if (pl->first) { + playlist_transfer_entries(mpctx->playlist, pl); + // current entry is replaced if (mpctx->playlist->current) playlist_remove(mpctx->playlist, mpctx->playlist->current); } else { |