diff options
author | Kővágó, Zoltán <dirty.ice.hu@gmail.com> | 2020-02-03 00:02:23 +0100 |
---|---|---|
committer | Gerd Hoffmann <kraxel@redhat.com> | 2020-02-06 14:31:20 +0100 |
commit | fb35c2cec58985f0b8d2733f1b91927542eeb3fd (patch) | |
tree | fe30d5f05ca1fde9d8d2c9a6f3bf1de3f4db0599 /audio/dsound_template.h | |
parent | 599eac4e5a41e828645594097daee39373acc3c0 (diff) | |
download | qemu-fb35c2cec58985f0b8d2733f1b91927542eeb3fd.zip qemu-fb35c2cec58985f0b8d2733f1b91927542eeb3fd.tar.gz qemu-fb35c2cec58985f0b8d2733f1b91927542eeb3fd.tar.bz2 |
audio/dsound: fix invalid parameters error
Windows (unlike wine) bails out when IDirectSoundBuffer8::Lock is called
with zero length. Also, hw->pos_emul handling was incorrect when
calling this function for the first time.
Signed-off-by: Kővágó, Zoltán <DirtY.iCE.hu@gmail.com>
Reported-by: KJ Liew <liewkj@yahoo.com>
Tested-by: Howard Spoelstra <hsp.cat7@gmail.com>
Message-id: fe9744216d9d421a2dbb09bcf5fa0dbd18f77ac5.1580684275.git.DirtY.iCE.hu@gmail.com
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Diffstat (limited to 'audio/dsound_template.h')
-rw-r--r-- | audio/dsound_template.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/audio/dsound_template.h b/audio/dsound_template.h index 7a15f91..9c5ce62 100644 --- a/audio/dsound_template.h +++ b/audio/dsound_template.h @@ -244,6 +244,7 @@ static int dsound_init_out(HWVoiceOut *hw, struct audsettings *as, goto fail0; } + ds->first_time = true; obt_as.endianness = 0; audio_pcm_init_info (&hw->info, &obt_as); |