Skip to content

Commit

Permalink
Fixing wrong merge
Browse files Browse the repository at this point in the history
  • Loading branch information
gents83 committed Nov 10, 2023
1 parent 8bc7140 commit 2cfa766
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions wgpu-core/src/device/global.rs
Original file line number Diff line number Diff line change
Expand Up @@ -485,9 +485,9 @@ impl<G: GlobalIdentityHandlerFactory> Global<G> {
let hub = A::hub(self);

log::debug!("Buffer {:?} is asked to be dropped", buffer_id);
let buffer = hub
.buffers
.get(buffer_id)
let mut buffer_guard = hub.buffers.write();
let buffer = buffer_guard
.take_and_mark_destroyed(buffer_id)
.map_err(|_| resource::DestroyError::Invalid)?;
buffer.destroy()
}
Expand Down

0 comments on commit 2cfa766

Please sign in to comment.