dsound: Avoid casts from COM object to interface.

Signed-off-by: Michael Stefaniuc <mstefani@redhat.de>
Signed-off-by: Andrew Eikum <aeikum@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
Michael Stefaniuc 2016-12-09 16:10:05 +01:00 committed by Alexandre Julliard
parent d7662881a5
commit 48b32c78d2
1 changed files with 2 additions and 2 deletions

View File

@ -452,8 +452,8 @@ static HRESULT DirectSoundDevice_CreateSoundBuffer(
if (device->primary) { if (device->primary) {
WARN("Primary Buffer already created\n"); WARN("Primary Buffer already created\n");
IDirectSoundBuffer_AddRef((LPDIRECTSOUNDBUFFER8)(device->primary)); IDirectSoundBuffer8_AddRef(&device->primary->IDirectSoundBuffer8_iface);
*ppdsb = (LPDIRECTSOUNDBUFFER)(device->primary); *ppdsb = (IDirectSoundBuffer *)&device->primary->IDirectSoundBuffer8_iface;
} else { } else {
hres = primarybuffer_create(device, &device->primary, dsbd); hres = primarybuffer_create(device, &device->primary, dsbd);
if (device->primary) { if (device->primary) {