mirror of
https://gitlab.com/qemu-project/qemu
synced 2024-09-06 18:05:37 +00:00
Revert "audio: fix wavcapture segfault"
This reverts commit cbaf25d1f5
.
Since previous commit every audio backend has a pcm_ops function
table. It's no longer necessary to test if the table is available.
Signed-off-by: Volker Rümelin <vr_qemu@t-online.de>
Message-Id: <20220301191311.26695-9-vr_qemu@t-online.de>
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
This commit is contained in:
parent
33940dd336
commit
669b95229d
|
@ -612,7 +612,7 @@ static size_t audio_pcm_sw_read(SWVoiceIn *sw, void *buf, size_t size)
|
||||||
total += isamp;
|
total += isamp;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (hw->pcm_ops && !hw->pcm_ops->volume_in) {
|
if (!hw->pcm_ops->volume_in) {
|
||||||
mixeng_volume (sw->buf, ret, &sw->vol);
|
mixeng_volume (sw->buf, ret, &sw->vol);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -718,7 +718,7 @@ static size_t audio_pcm_sw_write(SWVoiceOut *sw, void *buf, size_t size)
|
||||||
if (swlim) {
|
if (swlim) {
|
||||||
sw->conv (sw->buf, buf, swlim);
|
sw->conv (sw->buf, buf, swlim);
|
||||||
|
|
||||||
if (sw->hw->pcm_ops && !sw->hw->pcm_ops->volume_out) {
|
if (!sw->hw->pcm_ops->volume_out) {
|
||||||
mixeng_volume (sw->buf, swlim, &sw->vol);
|
mixeng_volume (sw->buf, swlim, &sw->vol);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue