Skip to content
This repository was archived by the owner on Feb 25, 2025. It is now read-only.

Commit 94dc7dd

Browse files
[Impeller] Null check for the device holder in the Vulkan context destructor (#42821)
1 parent 815db98 commit 94dc7dd

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

impeller/renderer/backend/vulkan/context_vk.cc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -107,7 +107,7 @@ uint64_t CalculateHash(void* ptr) {
107107
ContextVK::ContextVK() : hash_(CalculateHash(this)) {}
108108

109109
ContextVK::~ContextVK() {
110-
if (device_holder_->device) {
110+
if (device_holder_ && device_holder_->device) {
111111
[[maybe_unused]] auto result = device_holder_->device->waitIdle();
112112
}
113113
CommandPoolVK::ClearAllPools(this);

0 commit comments

Comments
 (0)