From e0a9ded6a3b80ddf4cd92c85e8548ac31eef88d9 Mon Sep 17 00:00:00 2001 From: Bernhard Schelling <14200249+schellingb@users.noreply.github.com> Date: Thu, 9 Jul 2020 22:32:43 +0900 Subject: [PATCH] Fix invalid calls to dinput_handle_message when input driver is not set to dinput --- gfx/common/win32_common.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/gfx/common/win32_common.c b/gfx/common/win32_common.c index 2aa89f129c..976a2340c6 100644 --- a/gfx/common/win32_common.c +++ b/gfx/common/win32_common.c @@ -1092,6 +1092,7 @@ LRESULT CALLBACK WndProcWGL(HWND hwnd, UINT message, taskbar_is_created = true; #endif #ifdef HAVE_DINPUT + if (input_get_ptr() == &input_dinput) { void* input_data = input_get_data(); if (input_data && dinput_handle_message(input_data, @@ -1155,6 +1156,7 @@ LRESULT CALLBACK WndProcGDI(HWND hwnd, UINT message, taskbar_is_created = true; #endif #ifdef HAVE_DINPUT + if (input_get_ptr() == &input_dinput) { void* input_data = input_get_data(); if (input_data && dinput_handle_message(input_data,