Commit 0d17228f authored by Bruno Jesus's avatar Bruno Jesus Committed by Alexandre Julliard

dinput: Handle NULL effect envelope before testing its parameters.

parent c1bc25dd
...@@ -585,9 +585,12 @@ static HRESULT WINAPI LinuxInputEffectImpl_SetParameters( ...@@ -585,9 +585,12 @@ static HRESULT WINAPI LinuxInputEffectImpl_SetParameters(
env->fade_length = 0; env->fade_length = 0;
env->fade_level = 0; env->fade_level = 0;
} }
else if(peff->lpEnvelope->dwAttackTime || peff->lpEnvelope->dwAttackLevel || else if(peff->lpEnvelope)
peff->lpEnvelope->dwFadeTime || peff->lpEnvelope->dwFadeLevel) {
WARN("Ignoring dinput envelope not supported in the linux effect\n"); if(peff->lpEnvelope->dwAttackTime || peff->lpEnvelope->dwAttackLevel ||
peff->lpEnvelope->dwFadeTime || peff->lpEnvelope->dwFadeLevel)
WARN("Ignoring dinput envelope not supported in the linux effect\n");
}
} }
/* Gain and Sample Period settings are not supported by the linux /* Gain and Sample Period settings are not supported by the linux
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment