From: Reimar D. <Rei...@gm...> - 2009-04-01 13:14:25
|
Hello, On Sat, Feb 07, 2009 at 04:15:48PM -0200, Miguel Freitas wrote: > I have been able to reproduce this problem using our pulseaudio driver > (which, imho, might not be ready for prime time - but that's another > question). It is just a matter of pausing/unpausing stream until it freezes > completely. > > The thing is that pulse is more sensitive to the currently unsafe xine pause > code than alsa. By unsafe i mean that it is possible that we may try to > write to a paused device. For pulse this is catastrophic: write will never > complete but the lock will be held, therefore we will not be able to > "uncork" it from a different thread => deadlock. Pulse's latency to obtain > delay and stuff should also contribute to trigger this bug. Sorry for heating up this old thread, but how sure are you this is the issue? MPlayer is single-threaded (so none of these issues should apply) but still there is a reproducible hang related to pausing. For some reason pa_stream_writable_size gets stuck at 0 since around pulseaudio version 0.9.11-0.9.13 (see also http://www.pulseaudio.org/ticket/440). Simply calling pa_stream_flush before unpausing seems to fix it (but is a bad hack)... Of course I don't know if you hit the same issue or not, neither can I be sure that MPlayer isn't wrong, given that no documentation at all seems to exist for pa_stream_cork... Greetings, Reimar Döffinger |