Procházet zdrojové kódy

net/hosts: Drop q lock when possible.

parazyd před 2 roky
rodič
revize
d9b8bcf84a
1 změnil soubory, kde provedl 1 přidání a 0 odebrání
  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 {