Skip to content

Commit

Permalink
Fix wrong pointer casts in win32 surface code
Browse files Browse the repository at this point in the history
The bad pattern was detected using clang/gcc but only on linux, so the
win32 code path never saw the fix.
  • Loading branch information
charles-lunarg committed Dec 19, 2023
1 parent 1529ba4 commit dc2a829
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion loader/extension_manual.c
Original file line number Diff line number Diff line change
Expand Up @@ -322,7 +322,7 @@ VKAPI_ATTR VkResult VKAPI_CALL terminator_GetDeviceGroupSurfacePresentModes2EXT(
abort(); /* Intentionally fail so user can correct issue. */
}
VkIcdSurface *icd_surface = (VkIcdSurface *)(uintptr_t)pSurfaceInfo->surface;
if (NULL != icd_surface->real_icd_surfaces && (VkSurfaceKHR)NULL != icd_surface->real_icd_surfaces[icd_index]) {
if (NULL != icd_surface->real_icd_surfaces && NULL != (void *)(uintptr_t)icd_surface->real_icd_surfaces[icd_index]) {
VkPhysicalDeviceSurfaceInfo2KHR surface_info_copy;
surface_info_copy.sType = pSurfaceInfo->sType;
surface_info_copy.pNext = pSurfaceInfo->pNext;
Expand Down

0 comments on commit dc2a829

Please sign in to comment.