vk: Fix vkDestroyObject dispatch for VkRenderPass
authorChad Versace <chad.versace@intel.com>
Wed, 15 Jul 2015 21:33:10 +0000 (14:33 -0700)
committerChad Versace <chad.versace@intel.com>
Wed, 15 Jul 2015 22:07:41 +0000 (15:07 -0700)
It called anv_device_free() instead of anv_DestroyRenderPass().

src/vulkan/device.c

index a4165ac1c817edec2177536fa065fad0aad2091a..2b8bcbe9e820c63f625f1e54a7e5f5b318c563ca 100644 (file)
@@ -1255,9 +1255,7 @@ VkResult anv_DestroyObject(
       return VK_SUCCESS;
 
    case VK_OBJECT_TYPE_RENDER_PASS:
-      /* These are trivially destroyable */
-      anv_device_free(device, (void *) _object);
-      return VK_SUCCESS;
+      return anv_DestroyRenderPass(_device, (VkRenderPass) _object);
 
    case VK_OBJECT_TYPE_DYNAMIC_VP_STATE:
       return anv_DestroyDynamicViewportState(_device, (VkDynamicViewportState) _object);