diff options
author | Narr the Reg <juangerman-13@hotmail.com> | 2023-01-07 17:40:21 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-01-07 17:40:21 +0100 |
commit | cc92b7fd94a1a86da4a765eaa0756642907d95dc (patch) | |
tree | af5aef3120f848b70c039b6e9cf02a5f67ce76a8 /src/video_core/vulkan_common/vulkan_device.cpp | |
parent | Merge pull request #9567 from german77/antialias (diff) | |
parent | vulkan_device: avoid attempt to access empty optional (diff) | |
download | yuzu-cc92b7fd94a1a86da4a765eaa0756642907d95dc.tar yuzu-cc92b7fd94a1a86da4a765eaa0756642907d95dc.tar.gz yuzu-cc92b7fd94a1a86da4a765eaa0756642907d95dc.tar.bz2 yuzu-cc92b7fd94a1a86da4a765eaa0756642907d95dc.tar.lz yuzu-cc92b7fd94a1a86da4a765eaa0756642907d95dc.tar.xz yuzu-cc92b7fd94a1a86da4a765eaa0756642907d95dc.tar.zst yuzu-cc92b7fd94a1a86da4a765eaa0756642907d95dc.zip |
Diffstat (limited to '')
-rw-r--r-- | src/video_core/vulkan_common/vulkan_device.cpp | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/src/video_core/vulkan_common/vulkan_device.cpp b/src/video_core/vulkan_common/vulkan_device.cpp index 77aee802d..07c984c5e 100644 --- a/src/video_core/vulkan_common/vulkan_device.cpp +++ b/src/video_core/vulkan_common/vulkan_device.cpp @@ -1520,8 +1520,12 @@ void Device::SetupFamilies(VkSurfaceKHR surface) { LOG_ERROR(Render_Vulkan, "Device lacks a present queue"); throw vk::Exception(VK_ERROR_FEATURE_NOT_PRESENT); } - graphics_family = *graphics; - present_family = *present; + if (graphics) { + graphics_family = *graphics; + } + if (present) { + present_family = *present; + } } void Device::SetupFeatures() { |