Commit 19b2351d authored by Kai Uwe Broulik's avatar Kai Uwe Broulik 🍇
Browse files

[StreamRestore] Fix equals check

`pa_channel_map_equal` returns `1` when equal and `0` when not equal.
We want to update it when it's *not* equal.


(cherry picked from commit d0140c03)
parent 94bf9987
...@@ -58,7 +58,7 @@ void StreamRestore::update(const pa_ext_stream_restore_info *info) ...@@ -58,7 +58,7 @@ void StreamRestore::update(const pa_ext_stream_restore_info *info)
Q_EMIT volumeChanged(); Q_EMIT volumeChanged();
Q_EMIT channelVolumesChanged(); Q_EMIT channelVolumesChanged();
} }
if (pa_channel_map_equal(&m_channelMap, &info->channel_map)) { if (!pa_channel_map_equal(&m_channelMap, &info->channel_map)) {
m_channels.clear(); m_channels.clear();
m_channels.reserve(info->channel_map.channels); m_channels.reserve(info->channel_map.channels);
for (int i = 0; i < info->channel_map.channels; ++i) { for (int i = 0; i < info->channel_map.channels; ++i) {
......
Supports Markdown
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