[FFmpeg-devel] UDP Timeout

Michael Niedermayer michaelni at gmx.at
Sat Jun 4 16:41:55 CEST 2011

On Sat, Jun 04, 2011 at 02:07:14PM +0100, JULIAN GARDNER wrote:
> >________________________________
> >From: Michael Niedermayer <michaelni at gmx.at>
> >To: FFmpeg development discussions and patches <ffmpeg-devel at ffmpeg.org>
> >Sent: Friday, 3 June 2011, 15:10
> >Subject: Re: [FFmpeg-devel] UDP Timeout
> >
> >On Fri, Jun 03, 2011 at 09:51:48AM +0100, JULIAN GARDNER wrote:
> >> Seeing a small problem in that if you have a UDP stream that stops running, we dont get a timeout from either ffmpeg or ffplay, i tracked this down to udp.c, not sure if it was my version or the modified verision.
> >> 
> >> Small mod here to return back if the return from select is an error or a timeout, my current version ran for 86mins, with modification, 20 seconds
> >
> >thats strange, the code looks like it would timeout after 1 second
> >(tv.tv_sec = 1;) with your modification
> >?
> whilst your right about the 1 second timeout you will see if you look the code that the only way to leave the while loop is for an error or data to arrive.
> The check <0 is only for errors, when no data is available we get a return of 0 as you said after 1 second.
> Please check again.

i know, we misunderstand each other
1 second is too short for a timeout that results after your patch
i understand it doesnt timeout before your patch

also maybe ff_network_wait_fd() should not be run after the select

Michael     GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

Republics decline into democracies and democracies degenerate into
despotisms. -- Aristotle
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 198 bytes
Desc: Digital signature
URL: <http://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20110604/5a57b6da/attachment.asc>

More information about the ffmpeg-devel mailing list