1
0
mirror of https://github.com/mpv-player/mpv synced 2025-03-07 22:57:42 +00:00

fix for crash when seeking with -novideo option

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@12968 b3059339-0415-0410-9bf9-f77b7e298cf2
This commit is contained in:
reimar 2004-08-07 14:20:28 +00:00
parent adad534913
commit f7e04468d6

View File

@ -366,7 +366,7 @@ void demux_seek_mpg(demuxer_t *demuxer,float rel_seek_secs,int flags){
newpos+=(demuxer->movi_end-demuxer->movi_start)*rel_seek_secs;
} else {
// time seek (secs)
if(!sh_video->i_bps) // unspecified or VBR
if(!sh_video || !sh_video->i_bps) // unspecified or VBR
newpos+=2324*75*rel_seek_secs; // 174.3 kbyte/sec
else
newpos+=sh_video->i_bps*rel_seek_secs;