dsound: Disable property sets if hardware doesn't support it.
This commit is contained in:
parent
13af056628
commit
3e1fcc0eb7
|
@ -197,9 +197,19 @@ HRESULT IKsBufferPropertySetImpl_Create(
|
|||
IDirectSoundBufferImpl *dsb,
|
||||
IKsBufferPropertySetImpl **piks)
|
||||
{
|
||||
PIDSDRIVERPROPERTYSET ps = NULL;
|
||||
IKsBufferPropertySetImpl *iks;
|
||||
TRACE("(%p,%p)\n",dsb,piks);
|
||||
|
||||
if (!dsb->hwbuf)
|
||||
return DSERR_INVALIDPARAM;
|
||||
|
||||
IDsDriver_QueryInterface(dsb->hwbuf, &IID_IDsDriverPropertySet, (void **)&ps);
|
||||
if (!ps)
|
||||
return DSERR_INVALIDPARAM;
|
||||
|
||||
IUnknown_Release(ps);
|
||||
|
||||
iks = HeapAlloc(GetProcessHeap(),HEAP_ZERO_MEMORY,sizeof(*iks));
|
||||
if (iks == 0) {
|
||||
WARN("out of memory\n");
|
||||
|
|
Loading…
Reference in New Issue