Fix invalid reference to dropped PipelineCache object in ComputePipeline (#1469)

* Fix invalid reference to dropped cache object in compute pipeline

This is achieved by preventing the cache object from being partially
moved.

This fixes issue #1466.

* Add entry to changelog
This commit is contained in:
stephan-cr 2021-01-11 17:16:06 +01:00 committed by GitHub
parent 2d60c08c10
commit 3e990190f7
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 1 deletions

View File

@ -2,6 +2,7 @@
- Added support for `ImageAspect` and YV12/NV12 formats, for use with the UnsafeImage API.
- Added basic VK_KHR_external_memory, VK_KHR_external_memory_fd, and VK_EXT_external_memory_dma_buf support.
- Fixed potential segmentation fault in `ComputePipeline` when referencing `PipelineCache` objects.
# Version 0.20.0 (2020-12-26)

View File

@ -163,7 +163,7 @@ impl<Pl> ComputePipeline<Pl> {
};
let cache_handle = match cache {
Some(cache) => cache.internal_object(),
Some(ref cache) => cache.internal_object(),
None => vk::NULL_HANDLE,
};