mirror of https://github.com/mpv-player/mpv
player: remove some inactive code
demux_seek() actually doesn't return seek success. Instead, it fails if the demuxer is flagged as unseekable (but this is checked explicitly at the beginning of this function), or if the seek target PTS is MP_NOPTS_VALUE (which can never happen).
This commit is contained in:
parent
ae7228c6a3
commit
9b654fd540
|
@ -276,14 +276,7 @@ static int mp_seek(MPContext *mpctx, struct seek_params seek,
|
|||
|
||||
if (hr_seek)
|
||||
demuxer_amount -= hr_seek_offset;
|
||||
int seekresult = demux_seek(mpctx->demuxer, demuxer_amount, demuxer_style);
|
||||
if (seekresult == 0) {
|
||||
if (need_reset) {
|
||||
reinit_audio_chain(mpctx);
|
||||
seek_reset(mpctx, !timeline_fallthrough, false);
|
||||
}
|
||||
return -1;
|
||||
}
|
||||
demux_seek(mpctx->demuxer, demuxer_amount, demuxer_style);
|
||||
|
||||
// Seek external, extra files too:
|
||||
for (int t = 0; t < mpctx->num_tracks; t++) {
|
||||
|
|
Loading…
Reference in New Issue