Changeset View
Changeset View
Standalone View
Standalone View
files/permit-compilation-with-vulkan-1.2.140.patch
- This file was added.
| --- a/ext/vulkan/vkerror.c | |||||
| +++ b/ext/vulkan/vkerror.c | |||||
| @@ -27,7 +27,7 @@ | |||||
| #include "gstvkerror.h" | |||||
| /* *INDENT-OFF* */ | |||||
| -static const struct | |||||
| +static const struct | |||||
| { | |||||
| VkResult result; | |||||
| const char *str; | |||||
| @@ -63,8 +63,6 @@ _vk_result_to_string (VkResult result) | |||||
| if (result >= 0) | |||||
| return NULL; | |||||
| - if (result < VK_RESULT_BEGIN_RANGE) | |||||
| - return "Unknown Error"; | |||||
| for (i = 0; i < G_N_ELEMENTS (vk_result_string_map); i++) { | |||||
| if (result == vk_result_string_map[i].result) | |||||
| @@ -87,8 +85,13 @@ gst_vulkan_error_to_g_error (VkResult result, GError ** error, | |||||
| return result; | |||||
| result_str = _vk_result_to_string (result); | |||||
| - if (result_str == NULL) | |||||
| - return result; | |||||
| + if (result_str == NULL) { | |||||
| + if (result < 0) { | |||||
| + result_str = "Unknown"; | |||||
| + } else { | |||||
| + return result; | |||||
| + } | |||||
| + } | |||||
Copyright © 2015-2021 Solus Project. The Solus logo is Copyright © 2016-2021 Solus Project. All Rights Reserved.