]> git.ipfire.org Git - thirdparty/squid.git/commitdiff
don't exchange too-large RTTs (it broke inet_htons()).
authorwessels <>
Tue, 12 May 1998 02:35:32 +0000 (02:35 +0000)
committerwessels <>
Tue, 12 May 1998 02:35:32 +0000 (02:35 +0000)
Limit at 60 seconds

src/net_db.cc

index 5bae8183f897374ee9db9b4cba22793d740965bc..6db765731f5662f515753be274573ac3ff929a76 100644 (file)
@@ -1,6 +1,6 @@
 
 /*
- * $Id: net_db.cc,v 1.98 1998/05/11 18:44:43 rousskov Exp $
+ * $Id: net_db.cc,v 1.99 1998/05/11 20:35:32 wessels Exp $
  *
  * DEBUG: section 37    Network Measurement Database
  * AUTHOR: Duane Wessels
@@ -997,6 +997,8 @@ netdbBinaryExchange(StoreEntry * s)
        next = (netdbEntry *) hash_next(addr_table);
        if (0.0 == n->rtt)
            continue;
+       if (n->rtt > 60000)     /* RTT > 1 MIN probably bogus */
+           continue;
        if (!safe_inet_addr(n->network, &addr))
            continue;
        buf[i++] = (char) NETDB_EX_NETWORK;