Skip to content

Commit 4b3bf07

Browse files
authored
Fix Android crash by setting waitAll to true in vkWaitForFences (gfx-rs#8769)
1 parent 81542ea commit 4b3bf07

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

wgpu-hal/src/vulkan/swapchain/native.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -468,9 +468,10 @@ impl Swapchain for NativeSwapchain {
468468
// latency, depending on how the platform implements waiting within
469469
// acquire.
470470
unsafe {
471+
// The `wait_all` argument must be `true` to avoid crash on some Android devices. See https://github.com/gfx-rs/wgpu/pull/8769
471472
self.device
472473
.raw
473-
.wait_for_fences(&[self.fence], false, timeout_ns)
474+
.wait_for_fences(&[self.fence], true, timeout_ns)
474475
.map_err(map_host_device_oom_and_lost_err)?;
475476

476477
self.device

0 commit comments

Comments
 (0)