A couple more clues: 1. Once the recording hangs like this, when I call pa_stream_disconnect on the record stream, pavucontrol says that my application is still recording. If I call pa_stream_disconnect before the recording hangs like this, then pavucontrol correctly reports that my application has stopped recording. 2. If I call pa_stream_peek more frequently, it is less likely for the pa_stream_peek get into the state where it only returns nbytes = 0. 3. I'm getting an assertion failure just by recording the monitor of analog stereo: Assertion '!e->next' failed at pulsecore/queue.c:106, function pa_queue_pop(). Aborting. #2 0x00007ffff046b8e5 in pa_queue_pop () from /usr/lib/x86_64-linux-gnu/pulseaudio/libpulsecommon-4.0.so #3 0x00007ffff046a94f in ?? () from /usr/lib/x86_64-linux-gnu/pulseaudio/ libpulsecommon-4.0.so #4 0x00007ffff5b20d7a in pa_mainloop_dispatch () from /usr/lib/x86_64-linux-gnu/libpulse.so.0 #5 0x00007ffff5b20f8c in pa_mainloop_iterate () from /usr/lib/x86_64-linux-gnu/libpulse.so.0 On Fri, Mar 13, 2015 at 12:09 PM, Andrew Kelley <superjoe30 at gmail.com> wrote: > I'm using the asynchronous API to record audio from a source. I'm able to > obtain about 1-5 seconds of audio and then every time I call > pa_stream_peek, I get nbytes = 0. Any troubleshooting suggestions? > > I have verified that the stream is not corked, not suspended, and I am in > fact calling pa_stream_drop every time that nbytes > 0. I also noticed that > when nbytes starts being 0 always, this other stream I have open, which is > a playback stream, also stops having room for playback buffers. > > This is pulseaudio version 1:4.0-0ubuntu22. > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.freedesktop.org/archives/pulseaudio-discuss/attachments/20150313/fc80000b/attachment.html>