mirror of
https://gitlab.freedesktop.org/mesa/vulkan-wsi-layer.git
synced 2025-12-20 02:10:13 +01:00
Detach proxies from queue
Instead of destroying the wayland buffers from the private data we just remove the proxies from the queue. Signed-off-by: Iason Paraskevopoulos <iason.paraskevopoulos@arm.com> Change-Id: I0e9dd158feaffa697ea30b3c49d41661ec3d924c
This commit is contained in:
parent
0866cfc352
commit
5e225e0896
1 changed files with 10 additions and 1 deletions
|
|
@ -75,6 +75,11 @@ public:
|
|||
return m_buffer.get();
|
||||
}
|
||||
|
||||
void remove_proxy()
|
||||
{
|
||||
wl_proxy_set_queue(reinterpret_cast<wl_proxy *>(m_buffer.get()), nullptr);
|
||||
}
|
||||
|
||||
private:
|
||||
wayland::wayland_owner<wl_buffer> m_buffer;
|
||||
};
|
||||
|
|
@ -99,7 +104,11 @@ swapchain::~swapchain()
|
|||
{
|
||||
for (auto &img : m_swapchain_images)
|
||||
{
|
||||
img.set_data(util::unique_ptr<swapchain_image_data>());
|
||||
auto data = img.get_data<wayland_image_data>();
|
||||
if (data != nullptr)
|
||||
{
|
||||
data->remove_proxy();
|
||||
}
|
||||
}
|
||||
|
||||
wl_display_roundtrip_queue(m_display, m_buffer_queue);
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue