Commit f34362c6 authored by Rémi Denis-Courmont's avatar Rémi Denis-Courmont

block_Fifo(Wake|Get|Show): always cancellation points

This is consistent with the comments in <vlc_block.h>.
So far, cancellation would only occur when sleeping was needed.
parent 530585d1
......@@ -431,6 +431,8 @@ void block_FifoEmpty( block_fifo_t *p_fifo )
*/
void block_FifoPace (block_fifo_t *fifo, size_t max_depth, size_t max_size)
{
vlc_testcancel ();
vlc_mutex_lock (&fifo->lock);
while ((fifo->i_depth > max_depth) || (fifo->i_size > max_size))
{
......@@ -483,6 +485,8 @@ block_t *block_FifoGet( block_fifo_t *p_fifo )
{
block_t *b;
vlc_testcancel( );
vlc_mutex_lock( &p_fifo->lock );
mutex_cleanup_push( &p_fifo->lock );
......@@ -523,6 +527,8 @@ block_t *block_FifoShow( block_fifo_t *p_fifo )
{
block_t *b;
vlc_testcancel( );
vlc_mutex_lock( &p_fifo->lock );
mutex_cleanup_push( &p_fifo->lock );
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment