kopper: guard unused variable behind ifdef

Acked-by: Yonggang Luo <luoyonggang@gmail.com>
Signed-off-by: David Heidelberg <david.heidelberg@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/19587>
This commit is contained in:
David Heidelberg 2022-11-07 21:03:25 +01:00 committed by Marge Bot
parent 92854b96bc
commit 9d81729c02

View file

@ -497,7 +497,9 @@ kopper_allocate_textures(struct dri_context *ctx,
__DRIdrawable *dri_drawable = drawable->dPriv;
const __DRIimageLoaderExtension *image = drawable->sPriv->image.loader;
struct kopper_drawable *cdraw = (struct kopper_drawable *)drawable;
#ifdef VK_USE_PLATFORM_XCB_KHR
struct kopper_screen *kscreen = (struct kopper_screen*)drawable->sPriv->driverPrivate;
#endif
bool is_window = cdraw->is_window;
bool is_pixmap = !is_window && cdraw->info.bos.sType == VK_STRUCTURE_TYPE_XCB_SURFACE_CREATE_INFO_KHR;