[Ffmpeg-devel] FFServer and RTSP

Michael Niedermayer michaelni
Fri Apr 6 13:26:42 CEST 2007


Hi

On Fri, Apr 06, 2007 at 12:32:07PM +0200, Luca Abeni wrote:
> Hi all,
> 
> On Thu, 2007-04-05 at 19:51 +0200, Luca Abeni wrote:
> [...]
> > The attached patch fixes this specific bug. After applying it, ffserver
> > gives a correct response "200 OK", but it still does not work. I am
> > investigating this second problem.
> Ok, I might have found something... The "poll()" loop in ffserver.c
> looks like this:
> do {
>     ret = poll(poll_table, poll_entry - poll_table, delay);
>     if (ret < 0 && errno != EAGAIN && errno != EINTR)
>         return -1;
> } while (ret <= 0);
> but this does not make sense to me.
> If poll() times out, it will return 0... And the loop will poll again?
> So, what's the point of using a timeout?
> The while() condition used to be while (ret == -1), which looks
> better... But commit 3340, which reads "ffserver fixes by (Koos Vriezen
> <koos.vriezen at xs4all dot nl>)" changed "== -1" in "<= 0".
> 
> So, I would be tempted to change "ret <= 0" in "ret < 0" - and this
> actually fixes RTP/RTSP!!! But I do not want to remove some "ffserver
> fixes".

if it fixes a bug and you are not aware of anything which breaks commit it
if something breaks you will find out ...

[...]

-- 
Michael     GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

The worst form of inequality is to try to make unequal things equal.
-- Aristotle
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
URL: <http://lists.mplayerhq.hu/pipermail/ffmpeg-devel/attachments/20070406/d421c7b3/attachment.pgp>



More information about the ffmpeg-devel mailing list