vk: Initialize dynamic state binding points to NULL
authorKristian Høgsberg Kristensen <kristian.h.kristensen@intel.com>
Thu, 28 May 2015 04:45:23 +0000 (21:45 -0700)
committerKristian Høgsberg Kristensen <kristian.h.kristensen@intel.com>
Thu, 28 May 2015 05:13:48 +0000 (22:13 -0700)
We rely on these being initialized to NULL so meta can reliably detect
whether or not they've been set. ds_state is also allowed to not be
present so we need a well-defined value for that.

src/vulkan/device.c

index 3c9c6d3e043c64636b6283032c34c033569d03b7..e2a2eebff2cfcc07344e36fb5c8d19d0ae11fb48 100644 (file)
@@ -2353,6 +2353,9 @@ VkResult anv_CreateCommandBuffer(
    cmd_buffer->dirty = 0;
    cmd_buffer->vb_dirty = 0;
    cmd_buffer->pipeline = NULL;
+   cmd_buffer->vp_state = NULL;
+   cmd_buffer->rs_state = NULL;
+   cmd_buffer->ds_state = NULL;
 
    *pCmdBuffer = (VkCmdBuffer) cmd_buffer;