summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorTimothy Arceri <[email protected]>2018-06-07 09:49:37 +1000
committerTimothy Arceri <[email protected]>2018-06-07 10:10:57 +1000
commit186988e28f9fe31ad4d08626586d5167051a14e7 (patch)
tree723ad9c52a42a0145c344ea02b43bee23c8e64e1 /src
parent44c614843c8785be57af06cc56208ad1497d05bc (diff)
radv: fix Coverity no effect control flow issue
swizzle is unsigned so "desc->swizzle[c] < 0" is never true. Reviewed-by: Bas Nieuwenhuizen <[email protected]>
Diffstat (limited to 'src')
-rw-r--r--src/amd/vulkan/radv_formats.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/amd/vulkan/radv_formats.c b/src/amd/vulkan/radv_formats.c
index 50ec904d514..958f2a2c821 100644
--- a/src/amd/vulkan/radv_formats.c
+++ b/src/amd/vulkan/radv_formats.c
@@ -921,7 +921,7 @@ bool radv_format_pack_clear_color(VkFormat format,
uint64_t clear_val = 0;
for (unsigned c = 0; c < 4; ++c) {
- if (desc->swizzle[c] < 0 || desc->swizzle[c] >= 4)
+ if (desc->swizzle[c] >= 4)
continue;
const struct vk_format_channel_description *channel = &desc->channel[desc->swizzle[c]];