[vlc-devel] mjpeg demux and infinite wait.

Rémi Denis-Courmont rem at videolan.org
Mon Jan 19 17:18:17 CET 2009

Le lundi 19 janvier 2009 18:08:49 Sébastien Escudier, vous avez écrit :
> Yes I think it is the case.
> Either I don't understand your answer, or my question was not clear.
> If the connection is lost, poll will wait as long as there is no data to
> read, and when I ask to quit, poll will return thanks to the HTTP access
> event pipe. The problem is : if the connection is lost, VLC will never
> close the stream and the input thread *by itself*.

poll() on a shutdown socket should return POLLHUP and POLLIN immediately, so I 
don't understand how VLC could get stuck in poll() in that case. If it 
actually does get stuck, then that'd point at a bug in the TCP/IP stack. But 
this is so unlikely that I'll assume I don't understand what you mean.

Or maybe VLC fails to detect the end of TCP stream and busy loops?

Rémi Denis-Courmont

More information about the vlc-devel mailing list