Do not seek to an invalid position.

Patch by {emild [at] cs technion ac il}


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@24102 b3059339-0415-0410-9bf9-f77b7e298cf2
This commit is contained in:
reimar 2007-08-19 21:22:27 +00:00
parent 0f6e7bd095
commit afe879eb99
1 changed files with 2 additions and 0 deletions

View File

@ -148,6 +148,8 @@ static offset_t mp_seek(URLContext *h, offset_t pos, int whence){
else
return -1;
if(pos<0)
return -1;
if(pos<stream->end_pos && stream->eof)
stream_reset(stream);
if(stream_seek(stream, pos)==0)