[pulseaudio-tickets] [Bug 51719] New: pa_sink_input_new() assumes that data->sample_spec is valid.

bugzilla-daemon at freedesktop.org bugzilla-daemon at freedesktop.org
Wed Jul 4 06:10:45 PDT 2012


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

             Bug #: 51719
           Summary: pa_sink_input_new() assumes that data->sample_spec is
                    valid.
    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: tanuk at iki.fi
         QAContact: pulseaudio-bugs at lists.freedesktop.org
                CC: lennart at poettering.net


If the sink input new data has all PA_SINK_INPUT_FIX_* flags set, then
pa_sink_input_new() should ignore the sample spec and channel map of the sink
input new data. That's not currently the case: at least
pa_format_info_from_sample_spec() is called with data->sample_spec as the
parameter, and that will crash if the sample spec is not valid.

One part of this problem is that it's not possible to set only one of sample
format and sample rate in pa_sink_input_new_data. This is a problem at least
with module-loopback: it accepts the "format" and "rate" module arguments, and
it's a perfectly reasonable thing for the user to set only one of them. If the
user sets only the sample rate, for example, then it should be possible for
module-loopback to only set the rate in pa_sink_input_new_data and leave the
format unspecified.

There's a FIXME item related to this, search for "FIXME" in this commit diff:
http://cgit.freedesktop.org/pulseaudio/pulseaudio/commit/?id=c6d8d1d7c19a105b224eac393e44bae319897b6b

(The same issue exists for source outputs too.)

-- 
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