| 241 | } |
| 242 | |
| 243 | void tq_receive_finish(ThreadQueue *tq, unsigned int stream_idx) |
| 244 | { |
| 245 | av_assert0(stream_idx < tq->nb_streams); |
| 246 | |
| 247 | pthread_mutex_lock(&tq->lock); |
| 248 | |
| 249 | /* mark the stream as recv-finished; |
| 250 | * next time the producer thread tries to send for this stream, it will |
| 251 | * get an EOF and send-finished flag will be set */ |
| 252 | tq->finished[stream_idx] |= FINISHED_RECV; |
| 253 | pthread_cond_broadcast(&tq->cond); |
| 254 | |
| 255 | pthread_mutex_unlock(&tq->lock); |
| 256 | } |
| 257 | |
| 258 | void tq_choke(ThreadQueue *tq, int choked) |
| 259 | { |
no test coverage detected