History

avutil/hwcontext_vulkan: Fix memleaks when transfer to vulkan

Without ff_vk_exec_discard_deps which is called by ff_vk_exec_wait, the reference count of hwframe context cannot reach zero due to circular reference created by ff_vk_exec_add_dep_frame. Fix #10873

Zhao Zhili committed 2 years ago

Commit 74e27d91 parent f6f06fb1 file · +1 −3Browse files

Unified · Split

libavutil/hwcontext_vulkan.c+1−3
@@ -3394,9 +3394,7 @@ static int transfer_image_buf(AVHWFramesContext *hwfc, AVFrame *f, · 3393 unmodified lines
33943394 if (err < 0)
33953395 return err;
33963396
3397− /* Wait for the operation to complete when downloading */
3398− if (to_buf)
3399− ff_vk_exec_wait(&p->vkctx, exec);
3397+ ff_vk_exec_wait(&p->vkctx, exec);
34003398
34013399 return 0;
34023400 }

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t