From 0d2f9b9b11b1848ed212d6751d6d2da0b97e3981 Mon Sep 17 00:00:00 2001 From: Dwedit Date: Wed, 2 May 2018 21:59:07 -0500 Subject: [PATCH 1/2] Fix __stdcall calling convention for Win32 32-bit builds --- gfx/common/win32_common.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gfx/common/win32_common.c b/gfx/common/win32_common.c index a46cf3b6d5..1c7e8d6558 100644 --- a/gfx/common/win32_common.c +++ b/gfx/common/win32_common.c @@ -259,8 +259,8 @@ typedef struct DISPLAYCONFIG_PATH_INFO_CUSTOM { UINT32 flags; } DISPLAYCONFIG_PATH_INFO_CUSTOM; -typedef LONG (*QUERYDISPLAYCONFIG)(UINT32, UINT32*, DISPLAYCONFIG_PATH_INFO_CUSTOM*, UINT32*, DISPLAYCONFIG_MODE_INFO_CUSTOM*, DISPLAYCONFIG_TOPOLOGY_ID_CUSTOM*); -typedef LONG (*GETDISPLAYCONFIGBUFFERSIZES)(UINT32, UINT32*, UINT32*); +typedef LONG (__stdcall *QUERYDISPLAYCONFIG)(UINT32, UINT32*, DISPLAYCONFIG_PATH_INFO_CUSTOM*, UINT32*, DISPLAYCONFIG_MODE_INFO_CUSTOM*, DISPLAYCONFIG_TOPOLOGY_ID_CUSTOM*); +typedef LONG (__stdcall *GETDISPLAYCONFIGBUFFERSIZES)(UINT32, UINT32*, UINT32*); static bool g_resized = false; bool g_restore_desktop = false; From 81457d74d30680f1497e68527b70b200fb055e05 Mon Sep 17 00:00:00 2001 From: Dwedit Date: Wed, 2 May 2018 22:09:20 -0500 Subject: [PATCH 2/2] Use `WINAPI` instead of `__stdcall`, not sure what keywords I can use or not, so I'll just use the macro instead of the keyword --- gfx/common/win32_common.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gfx/common/win32_common.c b/gfx/common/win32_common.c index 1c7e8d6558..39bd8bbdf6 100644 --- a/gfx/common/win32_common.c +++ b/gfx/common/win32_common.c @@ -259,8 +259,8 @@ typedef struct DISPLAYCONFIG_PATH_INFO_CUSTOM { UINT32 flags; } DISPLAYCONFIG_PATH_INFO_CUSTOM; -typedef LONG (__stdcall *QUERYDISPLAYCONFIG)(UINT32, UINT32*, DISPLAYCONFIG_PATH_INFO_CUSTOM*, UINT32*, DISPLAYCONFIG_MODE_INFO_CUSTOM*, DISPLAYCONFIG_TOPOLOGY_ID_CUSTOM*); -typedef LONG (__stdcall *GETDISPLAYCONFIGBUFFERSIZES)(UINT32, UINT32*, UINT32*); +typedef LONG (WINAPI *QUERYDISPLAYCONFIG)(UINT32, UINT32*, DISPLAYCONFIG_PATH_INFO_CUSTOM*, UINT32*, DISPLAYCONFIG_MODE_INFO_CUSTOM*, DISPLAYCONFIG_TOPOLOGY_ID_CUSTOM*); +typedef LONG (WINAPI *GETDISPLAYCONFIGBUFFERSIZES)(UINT32, UINT32*, UINT32*); static bool g_resized = false; bool g_restore_desktop = false;