GNOME Bugzilla – Bug 166250
[PATCH] [queue] When two threads are connected with queue, state change fails
Last modified: 2005-02-08 13:51:26 UTC
Steps to reproduce: 1. Start my testcase application. 2. 3. Stack trace: Other information:
More verbose description: You have two threads, they are connected with a queue, let's call them input and output thread. Now you change the state of the input thread to PAUSED while the output thread is PLAYING; Then change it back to PLAYING. Result: Scheduler crash. Workaround: The queue element must be paused before changing state of the input thread. Not nice.
Created attachment 36968 [details] testcase program
The pipeline is correctly interrupted, but queue sets an infinite interrupted state. The output threads, which continues playing, will always stay interrupted and return interrupt events. This is a bug in the queue element. I'm not sure what the expected behaviour is, really. Queue would either hang indefinately while the input is paused (which is fine, I think), or it could not allow gets while no input is active (which is counterintuitive for a buffering element). That's the only bug I see here. Apart from that, all's fine. I can try to fix queue sometime soon.
Created attachment 37154 [details] [review] proposed fix Reset interrupt state after interrupt (_release_locks()) is handled. Makes this testcase work.
Applied.