diff --git a/dlls/dmime/segmentstate.c b/dlls/dmime/segmentstate.c index 191b2f0bae1..afa67c03009 100644 --- a/dlls/dmime/segmentstate.c +++ b/dlls/dmime/segmentstate.c @@ -26,6 +26,9 @@ static HRESULT WINAPI IDirectMusicSegmentState8Impl_QueryInterface (LPDIRECTMUSI IDirectMusicSegmentState8Impl *This = (IDirectMusicSegmentState8Impl *)iface; TRACE("(%p, %s, %p)\n", This, debugstr_dmguid(riid), ppobj); + if (!riid || !ppobj) + return E_POINTER; + if (IsEqualIID(riid, &IID_IUnknown) || IsEqualIID(riid, &IID_IDirectMusicSegmentState) || IsEqualIID(riid, &IID_IDirectMusicSegmentState8)) {