This fixes a mismatch that occurred when the default type of VK_NULL_HANDLE and VK_DEFINE_NON_DISPATCHABLE_HANDLE had changed in the upstream XML. Because WineVulkan overrides the definition of VK_DEFINE_NON_DISPATCHABLE_HANDLE we must do the same for VK_NULL_HANDLE so that the types match.
Signed-off-by: Liam Middlebrook lmiddlebrook@nvidia.com Signed-off-by: Daniel Koch dkoch@nvidia.com --- dlls/winevulkan/make_vulkan | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/dlls/winevulkan/make_vulkan b/dlls/winevulkan/make_vulkan index 37ff78275fd..8614eaeb9f6 100755 --- a/dlls/winevulkan/make_vulkan +++ b/dlls/winevulkan/make_vulkan @@ -317,8 +317,6 @@ class VkDefine(object):
if name_elem is None: # <type category="define" name="some_name">some_value</type> - # At the time of writing there is only 1 define of this category - # 'VK_DEFINE_NON_DISPATCHABLE_HANDLE'. name = define.attrib.get("name")
# We override behavior of VK_DEFINE_NON_DISPATCHABLE handle as the default @@ -326,6 +324,10 @@ class VkDefine(object): # This complicates TRACEs in the thunks, so just use uint64_t. if name == "VK_DEFINE_NON_DISPATCHABLE_HANDLE": value = "#define VK_DEFINE_NON_DISPATCHABLE_HANDLE(object) typedef uint64_t object;" + # As VK_DEFINE_NON_DISPATCHABLE handle is overriden above, we must also override + # VK_NULL_HANDLE so that its type will match. + elif name == "VK_NULL_HANDLE": + value = "#define VK_NULL_HANDLE 0ULL" else: value = define.text return VkDefine(name, value)