mirror of
https://github.com/chatmail/core.git
synced 2026-04-20 23:16:30 +03:00
fix: avoid lock for probe_network, avoiding deadlock on startup
Closes #1532
This commit is contained in:
@@ -140,8 +140,10 @@ impl Context {
|
||||
info!(self, "starting IO");
|
||||
assert!(!self.is_io_running().await, "context is already running");
|
||||
|
||||
let l = &mut *self.inner.scheduler.write().await;
|
||||
l.start(self.clone()).await;
|
||||
{
|
||||
let l = &mut *self.inner.scheduler.write().await;
|
||||
l.start(self.clone()).await;
|
||||
}
|
||||
}
|
||||
|
||||
/// Returns if the IO scheduler is running.
|
||||
|
||||
Reference in New Issue
Block a user