From 6469d7268f2d4a48be47ae75da786156076844ae Mon Sep 17 00:00:00 2001 From: Yiwei Zhang Date: Wed, 11 Jun 2025 12:41:03 -0700 Subject: [PATCH] venus: suppress Coverity Uninitialized scalar variable Just false alarm. Adjusted the code to suppress it. Part-of: --- src/virtio/vulkan/vn_physical_device.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/src/virtio/vulkan/vn_physical_device.c b/src/virtio/vulkan/vn_physical_device.c index c92bdd2ddda..87486833f34 100644 --- a/src/virtio/vulkan/vn_physical_device.c +++ b/src/virtio/vulkan/vn_physical_device.c @@ -2874,11 +2874,10 @@ vn_GetPhysicalDeviceImageFormatProperties2( */ if (wsi_info && physical_dev->renderer_driver_id == VK_DRIVER_ID_INTEL_OPEN_SOURCE_MESA) { - if (pImageFormatInfo != &local_info.format) { - local_info.format = *pImageFormatInfo; - pImageFormatInfo = &local_info.format; - } + assert(!external_info); + local_info.format = *pImageFormatInfo; local_info.format.flags &= ~VK_IMAGE_CREATE_ALIAS_BIT; + pImageFormatInfo = &local_info.format; } /* Check if image format props is in the cache. */