Commit 649f8cbc authored by Elvis Angelaccio's avatar Elvis Angelaccio

Fix crash in pulseaudio playback

pa_sample_size() calls pa_assert(pa_sample_spec_valid(spec)), so it will
crash if the spec is invalid.

We prevent this by checking the spec validity on our own.

Differential Revision:
parent 6e84fc1c
......@@ -889,7 +889,7 @@ QList<unsigned int> Kwave::PlayBackPulseAudio::supportedBits
QList<unsigned int> list;
if (m_device_list.isEmpty() || !m_device_list.contains(device))
if (m_device_list.isEmpty() || !m_device_list.contains(device) || !pa_sample_spec_valid(&m_device_list[device].m_sample_spec))
return list;
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment