[pulseaudio-tickets] [Bug 48879] New: pa_stream_flush() does not reset record stream's readable size

bugzilla-daemon at freedesktop.org bugzilla-daemon at freedesktop.org
Wed Apr 18 07:48:46 PDT 2012


https://bugs.freedesktop.org/show_bug.cgi?id=48879

             Bug #: 48879
           Summary: pa_stream_flush() does not reset record stream's
                    readable size
    Classification: Unclassified
           Product: PulseAudio
           Version: unspecified
          Platform: Other
        OS/Version: All
            Status: NEW
          Severity: normal
          Priority: medium
         Component: core
        AssignedTo: pulseaudio-bugs at lists.freedesktop.org
        ReportedBy: aeikum at codeweavers.com
         QAContact: pulseaudio-bugs at lists.freedesktop.org
                CC: lennart at poettering.net


Created attachment 60256
  --> https://bugs.freedesktop.org/attachment.cgi?id=60256
C source demonstrating bug

As reported on the mailing list:
http://lists.freedesktop.org/archives/pulseaudio-discuss/2012-April/013328.html

The documentation for pa_stream_flush() reads, "This discards any audio in the
buffer." To me, this implies that pa_stream_readable_size() should return 0
after a call to pa_stream_flush(). Tanu Kaskinen on the mailing list agrees,
and asked me to report it here.

Attached is a program to demonstrate this failure. On my machine with
PulseAudio 1.1:
$ gcc -pthread -lpulse -o test pulse_capture_flush.c
$ ./test
pulse is ready now!
format: 3
rate: 44100
channels: 2
stream is ready now!
pre-sleep avail: 0 bytes
post-cork avail: 349360 bytes
post-flush avail: 349360 bytes
$

-- 
Configure bugmail: https://bugs.freedesktop.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA Contact for the bug.
You are the assignee for the bug.


More information about the pulseaudio-bugs mailing list