mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-03-31 21:07:02 +08:00
Ref T254, joystick windows avoid crash when shutting down
Temp.workaround, we do not really understand why it crashes here.
This commit is contained in:
@@ -38,16 +38,17 @@ namespace BlackInput
|
||||
|
||||
CJoystickWindows::~CJoystickWindows()
|
||||
{
|
||||
// release device before input
|
||||
if (m_directInputDevice)
|
||||
{
|
||||
m_directInputDevice->Unacquire();
|
||||
m_directInputDevice->Release();
|
||||
m_directInputDevice = nullptr;
|
||||
// currently disabled as it causes crashi
|
||||
// m_directInputDevice->Release();
|
||||
// m_directInputDevice = nullptr;
|
||||
}
|
||||
|
||||
if (m_directInput)
|
||||
{
|
||||
m_directInput->Release();
|
||||
//! \todo hack without input device this crashes
|
||||
if (m_directInputDevice) { m_directInput->Release(); }
|
||||
m_directInput = nullptr;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user