From fa667a35b296547a3579455658610b109fedf173 Mon Sep 17 00:00:00 2001 From: Charles Giessen Date: Tue, 19 Dec 2023 10:57:31 -0700 Subject: [PATCH] Make sure VkSurfaceKHR is cast to uintptr properly --- loader/wsi.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/loader/wsi.c b/loader/wsi.c index a8fdc3fd9..46c81b9ee 100644 --- a/loader/wsi.c +++ b/loader/wsi.c @@ -631,7 +631,7 @@ VKAPI_ATTR VkResult VKAPI_CALL terminator_CreateWin32SurfaceKHR(VkInstance insta } } - *pSurface = (VkSurfaceKHR)(pIcdSurface); + *pSurface = (VkSurfaceKHR)(uintptr_t)pIcdSurface; out: @@ -1595,7 +1595,7 @@ VKAPI_ATTR VkResult VKAPI_CALL terminator_CreateMetalSurfaceEXT(VkInstance insta } } } - *pSurface = (VkSurfaceKHR)icd_surface; + *pSurface = (VkSurfaceKHR)(uintptr_t)icd_surface; out: if (result != VK_SUCCESS && icd_surface != NULL) { @@ -2571,7 +2571,7 @@ VKAPI_ATTR VkResult VKAPI_CALL terminator_CreateImagePipeSurfaceFUCHSIA(VkInstan } } - *pSurface = (VkSurfaceKHR)(pIcdSurface); + *pSurface = (VkSurfaceKHR)(uintptr_t)pIcdSurface; out: