diff options
author | reimar <reimar@b3059339-0415-0410-9bf9-f77b7e298cf2> | 2007-08-20 09:28:44 +0000 |
---|---|---|
committer | reimar <reimar@b3059339-0415-0410-9bf9-f77b7e298cf2> | 2007-08-20 09:28:44 +0000 |
commit | 80ef41dccfb69b2d55ced1ad2ae68b1ea9d1d3ff (patch) | |
tree | d0d80d3b886555e930a63a4934d3044fa0b4b84e | |
parent | 08dd16470b70ffaae2e9914c8f6d28ae8784c6ec (diff) |
We can support SEEK_END seeks only when stream->end_pos is known
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@24105 b3059339-0415-0410-9bf9-f77b7e298cf2
-rw-r--r-- | libmpdemux/demux_lavf.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/libmpdemux/demux_lavf.c b/libmpdemux/demux_lavf.c index 4116fcb874..20dba6c1f0 100644 --- a/libmpdemux/demux_lavf.c +++ b/libmpdemux/demux_lavf.c @@ -141,7 +141,7 @@ static offset_t mp_seek(URLContext *h, offset_t pos, int whence){ mp_msg(MSGT_HEADER,MSGL_DBG2,"mp_seek(%p, %d, %d)\n", h, (int)pos, whence); if(whence == SEEK_CUR) pos +=stream_tell(stream); - else if(whence == SEEK_END) + else if(whence == SEEK_END && stream->end_pos > 0) pos += stream->end_pos; else if(whence == SEEK_SET) pos += stream->start_pos; |