void av_thread_message_flush(AVThreadMessageQueue *mq)

{

#if HAVE_THREADS

    int used, off;

    void *free_func = mq->free_func;



    pthread_mutex_lock(&mq->lock);

    used = av_fifo_size(mq->fifo);

    if (free_func)

        for (off = 0; off < used; off += mq->elsize)

            av_fifo_generic_peek_at(mq->fifo, mq, off, mq->elsize, free_func_wrap);

    av_fifo_drain(mq->fifo, used);

    pthread_cond_broadcast(&mq->cond);

    pthread_mutex_unlock(&mq->lock);

#endif /* HAVE_THREADS */

}

void av_thread_message_flush(AVThreadMessageQueue *mq)

{

#if HAVE_THREADS

    int used, off;

    void *free_func = mq->free_func;



    pthread_mutex_lock(&mq->lock);

    used = av_fifo_size(mq->fifo);

    if (free_func)

        for (off = 0; off < used; off += mq->elsize)

            av_fifo_generic_peek_at(mq->fifo, mq, off, mq->elsize, free_func_wrap);

    av_fifo_drain(mq->fifo, used);

    pthread_cond_broadcast(&mq->cond);

    pthread_mutex_unlock(&mq->lock);

#endif 

}

    pthread_cond_broadcast(&mq->cond);     pthread_cond_broadcast(&mq->cond);     pthread_cond_broadcast(&mq->cond);
void FUNC_0(AVThreadMessageQueue *VAR_0)

{

#if HAVE_THREADS

    int used, off;

    void *free_func = VAR_0->free_func;



    pthread_mutex_lock(&VAR_0->lock);

    used = av_fifo_size(VAR_0->fifo);

    if (free_func)

        for (off = 0; off < used; off += VAR_0->elsize)

            av_fifo_generic_peek_at(VAR_0->fifo, VAR_0, off, VAR_0->elsize, free_func_wrap);

    av_fifo_drain(VAR_0->fifo, used);

    pthread_cond_broadcast(&VAR_0->cond);

    pthread_mutex_unlock(&VAR_0->lock);

#endif 

}

void FUNC_0(AVThreadMessageQueue *VAR_0)
{ #if HAVE_THREADS
int used, off; void *free_func = VAR_0->free_func; pthread_mutex_lock(&VAR_0->lock); used = av_fifo_size(VAR_0->fifo); if (free_func)
for (off = 0; off < used; off += VAR_0->elsize) av_fifo_generic_peek_at(VAR_0->fifo, VAR_0, off, VAR_0->elsize, free_func_wrap); av_fifo_drain(VAR_0->fifo, used); pthread_cond_broadcast(&VAR_0->cond); pthread_mutex_unlock(&VAR_0->lock); #endif
}