mirror of
https://github.com/reactos/reactos.git
synced 2026-07-07 01:44:20 +08:00
check for NULL pointer
svn path=/trunk/; revision=34425
This commit is contained in:
@@ -577,6 +577,11 @@ static HRESULT WINAPI IDirectSoundImpl_SetCooperativeLevel(
|
||||
IDirectSoundImpl *This = (IDirectSoundImpl *)iface;
|
||||
TRACE("(%p,%p,%s)\n",This,hwnd,dumpCooperativeLevel(level));
|
||||
|
||||
if (This->device == NULL) {
|
||||
WARN("not initialized\n");
|
||||
return DSERR_UNINITIALIZED;
|
||||
}
|
||||
|
||||
if (level==DSSCL_PRIORITY || level==DSSCL_EXCLUSIVE) {
|
||||
WARN("level=%s not fully supported\n",
|
||||
level==DSSCL_PRIORITY ? "DSSCL_PRIORITY" : "DSSCL_EXCLUSIVE");
|
||||
|
||||
Reference in New Issue
Block a user