]> git.ipfire.org Git - thirdparty/squid.git/commitdiff
fixed 8k page leak
authorwessels <>
Tue, 17 Sep 1996 11:16:57 +0000 (11:16 +0000)
committerwessels <>
Tue, 17 Sep 1996 11:16:57 +0000 (11:16 +0000)
src/icmp.cc

index 331e321f257013be839929131d56f2832661b8f1..16c88e264833833e7e5842b8f9627e7d7f53c61a 100644 (file)
@@ -1,6 +1,6 @@
 
 /*
- * $Id: icmp.cc,v 1.4 1996/09/16 21:50:24 wessels Exp $
+ * $Id: icmp.cc,v 1.5 1996/09/17 05:16:57 wessels Exp $
  *
  * DEBUG: section 37    ICMP Routines
  * AUTHOR: Duane Wessels
@@ -245,12 +245,12 @@ icmpRecv(int unused1, void *unused2)
     ip = (struct iphdr *) pkt;
     iphdrlen = ip->ip_hl << 2;
     icmp = (struct icmphdr *) (pkt + iphdrlen);
-    if (icmp->icmp_type != ICMP_ECHOREPLY)
-       return;
-    if (icmp->icmp_id != icmp_ident)
-       return;
-    hops = ipHops(ip->ip_ttl);
-    icmpProcessReply(&from, icmp, hops);
+    if (icmp->icmp_type == ICMP_ECHOREPLY) {
+       if (icmp->icmp_id == icmp_ident) {
+           hops = ipHops(ip->ip_ttl);
+           icmpProcessReply(&from, icmp, hops);
+       }
+    }
     put_free_8k_page(pkt);
 }