[MPlayer-dev-eng] Re: [PATCH] Seek in http-streams

eviv bulgroz ebulgroz at yahoo.com
Sun Feb 29 11:28:06 CET 2004


--- Valentine Zaretsky <valik+mplayerdev at email.dp.ua> wrote:
> Hi!
> 
> Well... It's even simpler and patching stream_file.c is not needed
> This patch is against CVS and fixes only bugs caused by my http-seek 
> patch (this time all of them, I hope), but I think that stream_seek_long 
> function needs further  rewriting -- at least some parts of it output 
> info message and return 1 instead of error message and returning 0 when 
> seek cannot be done.
> 

No, Valentine, this wrong, s->seek points to seek_forward and seek_forward has a bug, it should be
fixed or not be used. Masking the error by changing the return value doesn't help either, since no
error is returned! And forward seeking is used; like in aviheader for example to skip JUNK chunks:

read_avi_header -> stream_skip -> stream_seek -> cache_stream_seek_long -> seek_forward

seek_forward problem, is that it doesn't actualize  s->buf_pos, s->buf_len, s->pos 
Now stdin reading works again properly with the return 0 reversed ant the seek_forward fix applied

__________________________________
Do you Yahoo!?
Get better spam protection with Yahoo! Mail.
http://antispam.yahoo.com/tools
-------------- next part --------------
A non-text attachment was scrubbed...
Name: streamfix.diff
Type: text/x-diff
Size: 2599 bytes
Desc: streamfix.diff
URL: <http://lists.mplayerhq.hu/pipermail/mplayer-dev-eng/attachments/20040229/fc060ea4/attachment.diff>


More information about the MPlayer-dev-eng mailing list