From 9845f1d76a582276c618fd1db6e9422bbb84761b Mon Sep 17 00:00:00 2001 From: Connor McLaughlin Date: Thu, 3 Jun 2021 14:04:12 +1000 Subject: [PATCH] DInputControllerInterface: Fix crash on shutdown --- src/frontend-common/dinput_controller_interface.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/frontend-common/dinput_controller_interface.cpp b/src/frontend-common/dinput_controller_interface.cpp index 5aed98cce..cbcf6bf00 100644 --- a/src/frontend-common/dinput_controller_interface.cpp +++ b/src/frontend-common/dinput_controller_interface.cpp @@ -20,6 +20,8 @@ DInputControllerInterface::DInputControllerInterface() = default; DInputControllerInterface::~DInputControllerInterface() { + m_controllers.clear(); + m_dinput.Reset(); if (m_dinput_module) FreeLibrary(m_dinput_module); }