vulkan: Fix GstMemory leaks
Allocated GstMemory should be freed with g_free()
This commit is contained in:
parent
f3587c61ba
commit
68057cee98
@ -332,6 +332,8 @@ _vk_buffer_mem_free (GstAllocator * allocator, GstMemory * memory)
|
|||||||
mem->notify (mem->user_data);
|
mem->notify (mem->user_data);
|
||||||
|
|
||||||
gst_object_unref (mem->device);
|
gst_object_unref (mem->device);
|
||||||
|
|
||||||
|
g_free (mem);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -247,6 +247,8 @@ _vk_mem_free (GstAllocator * allocator, GstMemory * memory)
|
|||||||
vkFreeMemory (mem->device->device, mem->mem_ptr, NULL);
|
vkFreeMemory (mem->device->device, mem->mem_ptr, NULL);
|
||||||
|
|
||||||
gst_object_unref (mem->device);
|
gst_object_unref (mem->device);
|
||||||
|
|
||||||
|
g_free (mem);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
Loading…
x
Reference in New Issue
Block a user