[vlc-devel] stream_Block blocking?

Brian Raymond braymond at attemptatsanity.com
Mon May 21 22:57:37 CEST 2007


I was looking at stream_Block in vlc_stream.h and the comment indicates 
it's non blocking however it seems to block until the there are enough 
bytes available to fill the requested size.

/**
 * Read "i_size" bytes and store them in a block_t. If less than "i_size"
 * bytes are available then return what is left and if nothing is availble,
 * return NULL.
 */

First, is the behavior supposed to match the comment or is the comment 
incorrect and it is supposed to block?

I am playing with a demuxer that will read from a pipe however the size 
is unknown so unless there is a member in p_demux I overlooked that 
provides the size I do not know of an easy way to call stream_Block( 
p_demux->s, 4096 ) and have it return immediately with the data that is 
available.

Thanks.

- Brian



-- 
This is the vlc-devel mailing-list, see http://www.videolan.org/vlc/
To unsubscribe, please read http://developers.videolan.org/lists.html



More information about the vlc-devel mailing list