mirror of
https://github.com/servo/servo.git
synced 2025-08-06 14:10:11 +01:00
Make WebGPU resource creation fully async
Remove some garbage code in adapter id checks Prevent panic during shutdown if using WebGPU
This commit is contained in:
parent
a3446579ec
commit
f4d0183568
6 changed files with 65 additions and 165 deletions
|
@ -179,10 +179,16 @@ impl GPUBufferMethods for GPUBuffer {
|
|||
},
|
||||
_ => {},
|
||||
};
|
||||
self.channel
|
||||
if let Err(e) = self
|
||||
.channel
|
||||
.0
|
||||
.send(WebGPURequest::DestroyBuffer(self.buffer.0))
|
||||
.unwrap();
|
||||
{
|
||||
warn!(
|
||||
"Failed to send WebGPURequest::DestroyBuffer({:?}) ({})",
|
||||
self.buffer.0, e
|
||||
);
|
||||
};
|
||||
*self.state.borrow_mut() = GPUBufferState::Destroyed;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue