Fix source volume setting in PaClient::setVolume 51/9151/3
authorMatt Porter <mporter@konsulko.com>
Thu, 20 Apr 2017 03:39:07 +0000 (23:39 -0400)
committerMatt Porter <mporter@konsulko.com>
Fri, 21 Apr 2017 02:00:10 +0000 (22:00 -0400)
Fix error resulting in sources not being found due to searching
the sink cache hash.

AGL-Bug: SPEC-548
Change-Id: Icd5a75af7a5fc2e0e125d96910af034e4d0873a3
Signed-off-by: Matt Porter <mporter@konsulko.com>
app/paclient.cpp

index 9360685..58d8fad 100644 (file)
@@ -68,7 +68,7 @@ void PaClient::setVolume(uint32_t type, uint32_t index, uint32_t channel, uint32
                }
                pa_operation_unref(o);
        } else if (type == C_SOURCE) {
-               cvolume = m_sink_states.value(index);
+               cvolume = m_source_states.value(index);
                cvolume->values[channel] = volume;
                if (!(o = pa_context_set_source_volume_by_index(c, index, cvolume, set_source_volume_cb, NULL))) {
                        qWarning() << "PaClient: set source #" << index <<