From 446b052657fee7cc364ae33ba2644fafc65a1587 Mon Sep 17 00:00:00 2001 From: Alex Janka Date: Sun, 29 Oct 2023 10:22:57 +1100 Subject: [PATCH] fix double free --- librashader-runtime-vk/src/memory.rs | 3 --- 1 file changed, 3 deletions(-) diff --git a/librashader-runtime-vk/src/memory.rs b/librashader-runtime-vk/src/memory.rs index e775ef2..d7c783f 100644 --- a/librashader-runtime-vk/src/memory.rs +++ b/librashader-runtime-vk/src/memory.rs @@ -186,9 +186,6 @@ impl Drop for RawVulkanBuffer { fn drop(&mut self) { unsafe { ManuallyDrop::drop(&mut self.buffer); - if self.buffer.handle != vk::Buffer::null() { - self.buffer.device.destroy_buffer(self.buffer.handle, None); - } } } }