vulkan/wsi: initialise image_index to 0 in x11_manage_fifo_queues

Supresses a maybe-uninitialized warning with GCC 8.

Note: image_index should always be initialised due to the result check,
      but the compiler doesn't see that.

Signed-off-by: Kai Wasserbäch <kai@dev.carbon-project.org>
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
This commit is contained in:
Kai Wasserbäch 2018-08-17 16:32:33 +02:00 committed by Timothy Arceri
parent 6f0647c0b2
commit 2c020dbf06

View File

@ -991,7 +991,7 @@ x11_manage_fifo_queues(void *state)
* before that point so the client should be able to acquire any image
* other than the currently presented one.
*/
uint32_t image_index;
uint32_t image_index = 0;
result = wsi_queue_pull(&chain->present_queue, &image_index, INT64_MAX);
assert(result != VK_TIMEOUT);
if (result < 0) {