mirror of
https://github.com/gfx-rs/wgpu.git
synced 2026-04-22 03:02:01 -04:00
Fix Panic in Surface Configure (#4635)
This commit is contained in:
committed by
GitHub
parent
8547226176
commit
873f19dec6
@@ -2296,12 +2296,12 @@ impl<G: GlobalIdentityHandlerFactory> Global<G> {
|
||||
log::info!("configuring surface with {:?}", config);
|
||||
|
||||
let error = 'outer: loop {
|
||||
let hub = A::hub(self);
|
||||
let mut token = Token::root();
|
||||
|
||||
// User callbacks must not be called while we are holding locks.
|
||||
let user_callbacks;
|
||||
{
|
||||
let hub = A::hub(self);
|
||||
let mut token = Token::root();
|
||||
|
||||
let (mut surface_guard, mut token) = self.surfaces.write(&mut token);
|
||||
let (adapter_guard, mut token) = hub.adapters.read(&mut token);
|
||||
let (device_guard, mut token) = hub.devices.read(&mut token);
|
||||
|
||||
Reference in New Issue
Block a user