This is an automated email from the git hooks/post-receive script.

Git pushed a commit to branch master
in repository ffmpeg.

The following commit(s) were added to refs/heads/master by this push:
     new 967f0ffb10 avutil/vulkan: avoid crash on null vkGetDeviceQueue2
967f0ffb10 is described below

commit 967f0ffb10c3e77cfb8f7e1ba1cbed2e0a29d127
Author:     Tim Blechmann <[email protected]>
AuthorDate: Tue Sep 22 11:40:08 2026 +0800
Commit:     Lynne <[email protected]>
CommitDate: Sat Nov 7 10:30:33 2026 +0000

    avutil/vulkan: avoid crash on null vkGetDeviceQueue2
    
    vkGetDeviceQueue2 is core since Vulkan 1.1 and is always loaded by
    ff_vk_load_functions() regardless of which extensions are enabled, but
    some drivers/loaders can still return a non-functional dispatch entry
    for it depending on how the instance/device were set up (e.g. an
    imported device from an app that declared an insufficient
    VkApplicationInfo::apiVersion). Calling it then crashes instead of
    failing cleanly. Guard the call and return AVERROR_EXTERNAL if the
    function pointer is unavailable.
---
 libavutil/vulkan.c | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/libavutil/vulkan.c b/libavutil/vulkan.c
index 6d5038a584..76e9a773a5 100644
--- a/libavutil/vulkan.c
+++ b/libavutil/vulkan.c
@@ -585,6 +585,10 @@ int ff_vk_exec_pool_init(FFVulkanContext *s, 
AVVulkanDeviceQueueFamily *qf,
             .queueFamilyIndex = qf->idx,
             .queueIndex       = e->qi,
         };
+        if (!vk->GetDeviceQueue2) {
+            av_log(s, AV_LOG_ERROR, "vkGetDeviceQueue2 is unavailable on this 
device\n");
+            return AVERROR_EXTERNAL;
+        }
         vk->GetDeviceQueue2(s->hwctx->act_dev, &qinfo, &e->queue);
     }
 

-- 
To stop receiving notification emails like this one, please contact
[email protected].
_______________________________________________
ffmpeg-cvslog mailing list -- [email protected]
To unsubscribe send an email to [email protected]

Reply via email to