Просмотр исходного кода

net/hosts: Drop q lock when possible.

parazyd 2 лет назад
Родитель
Сommit
d9b8bcf84a
1 измененных файлов с 1 добавлено и 0 удалено
  1. 1 0
      src/net/hosts/store.rs

+ 1 - 0
src/net/hosts/store.rs

@@ -665,6 +665,7 @@ impl Hosts {
             if *retries == self.settings.hosts_quarantine_limit {
                 debug!(target: "net::hosts::quarantine()", "Reached quarantine limited after {:?}", timer.elapsed());
                 debug!(target: "net::hosts::quarantine()", "Removing from hostlist {}", addr);
+                drop(q);
                 self.downgrade_host(addr, last_seen).await;
             }
         } else {