queue, queue2: Flush internal queue on flow error
This is to fix an infinitely blocked upstream streaming thread if
- upstream has fixed-size buffer pool, some H/W decoders for example
- downstream returned flow error without releasing buffer
When the fixed-size buffer pool hits its configured max-buffers and also downstream of queue returned flow error without releasing corresponding buffer, upstream has no chance to run the next processing loop because it will be blocked by acquire_buffer(), and therefore downstream flow will not be propagated to upstream.