Callstack corruption in FSteamVRInputDevice::ProcessActionEvents(...)
spencerparkin opened this issue · comments
Hi. I'm getting the following crash...
Unhandled exception at 0x06E6556A in Driver-Win32-DebugGame.exe: Stack cookie instrumentation code detected a stack-based buffer overrun.
...with the following callstack...
Driver-Win32-DebugGame.exe!__report_gsfailure(...) Line 220 C Driver-Win32-DebugGame.exe!FSteamVRInputDevice::ProcessActionEvents(FSteamVRInputActionSet SteamVRInputActionSet) Line 4640 C++ Driver-Win32-DebugGame.exe!FSteamVRInputDevice::SendControllerEvents() Line 368 C++ Driver-Win32-DebugGame.exe!FWindowsApplication::PollGameDeviceState(const float TimeDelta) Line 2715 C++ Driver-Win32-DebugGame.exe!FSlateApplication::PollGameDeviceState() Line 1305 C++ Driver-Win32-DebugGame.exe!FEngineLoop::Tick() Line 4810 C++ [Inline Frame] Driver-Win32-DebugGame.exe!EngineTick() Line 62 C++ Driver-Win32-DebugGame.exe!GuardedMain(const wchar_t * CmdLine) Line 169 C++ Driver-Win32-DebugGame.exe!GuardedMainWrapper(const wchar_t * CmdLine) Line 150 C++ Driver-Win32-DebugGame.exe!WinMain(HINSTANCE__ * hInInstance, HINSTANCE__ * hPrevInstance, char * __formal, int nCmdShow) Line 268 C++ [External Code] kernel32.dll![Frames below may be incorrect and/or missing, no symbols loaded for kernel32.dll] Unknown
I've narrowed the callstack corruption down to the following two lines of code (which don't appear consecutively.)
EVRInputError ActionStateError = VRInput()->GetDigitalActionData(Action.Handle, &DigitalData, sizeof(DigitalData), k_ulInvalidInputValueHandle);
EVRInputError ActionStateError = VRInput()->GetAnalogActionData(Action.Handle, &AnalogData, sizeof(AnalogData), k_ulInvalidInputValueHandle);
I think my SteamVR plugin version is 1.12.something, but I'll have to check again when I'm back at work.
Also, I'm going to try upgrading to whatever the latest plugin is. We're using UE4 4.26.1.
Some of the action handles are invalid, which causes the GetDigitalActionData
and GetAnalogActionData
calls to return an error, but I wouldn't expect either function to corrupt the callstack, which they have the opportunity to do since DigitalData
and AnalogData
are both allocated on the callstack.
You might be able to reproduce this by adding action mappings for analog inputs then running SteamVR with your motion controllers turned off. Other than that, I'm not sure what might be causing this.
Lastly, this corruption is happening when the plugin calls out to OpenVR, so maybe the problem is in OpenVR? If so, maybe I need to upgrade my version of that?
Thanks for any thoughts you may have.
Hi @spencerparkin - can you send over the crashdump so i can investigate?
thanks,
Rune
I'm sorry, no crash dump is ever generated. It just hangs.
@spencerparkin - sorry I missed your reply. I thought the game was crashing ? Can you let me know how you got the callstack and perhaps post the full one here?
@spencerparkin - hi just checking if you've had a chance to grab the callstack ? Otherwise, can you provide a minimum repro project for me to look at? Thanks
closing, stale issue