# HG changeset patch # User arpi # Date 999037442 0 # Node ID 00505a8fa2b48d46ae3447bfac1438242b738f74 # Parent 1a8e6e3bee3d871b1ed61b989f65582d145228fd sig11 for abs seek in bad avi file fixed diff -r 1a8e6e3bee3d -r 00505a8fa2b4 demux_avi.c --- a/demux_avi.c Tue Aug 28 21:47:20 2001 +0000 +++ b/demux_avi.c Tue Aug 28 22:24:02 2001 +0000 @@ -497,8 +497,8 @@ int total=sh_video->video.dwLength; if(total<=1){ // bad video header, try to get it from audio - total=sh_video->fps*sh_audio->audio.dwLength/sh_audio->wf->nAvgBytesPerSec; - if(total<1){ + if(sh_audio) total=sh_video->fps*sh_audio->audio.dwLength/sh_audio->wf->nAvgBytesPerSec; + if(total<=1){ mp_msg(MSGT_SEEK,MSGL_WARN,"Couldn't determine number of frames (for absoulte seek) \n"); total=0; }