Fixes: 1720bbd353d87412754f ("anv/wsi: split image alloc/free out to separate fns.")
Cc: "13.0" <mesa-stable@lists.freedesktop.org>
Signed-off-by: Eric Engestrom <eric@engestrom.ch>
Signed-off-by: Dave Airlie <airlied@redhat.com>
wl_display_roundtrip(chain->display->display);
close(fd);
+ if (!image->buffer)
+ goto fail_image;
+
wl_proxy_set_queue((struct wl_proxy *)image->buffer, chain->queue);
wl_buffer_add_listener(image->buffer, &buffer_listener, image);
return VK_SUCCESS;
+fail_image:
chain->base.image_fns->free_wsi_image(vk_device, pAllocator,
image->image, image->memory);