]> The Tcpdump Group git mirrors - tcpdump/blobdiff - print-ip.c
Get rid of an extra newline.
[tcpdump] / print-ip.c
index c14d2fc2977bdedfb5a39166fbd23261cbe2b74f..c24f5d520a34598ca1a5b4e320f0475f8ae91647 100644 (file)
@@ -21,7 +21,7 @@
 
 #ifndef lint
 static const char rcsid[] =
-    "@(#) $Header: /tcpdump/master/tcpdump/print-ip.c,v 1.102 2001-11-16 02:17:36 itojun Exp $ (LBL)";
+    "@(#) $Header: /tcpdump/master/tcpdump/print-ip.c,v 1.104 2002-05-29 09:47:04 guy Exp $ (LBL)";
 #endif
 
 #ifdef HAVE_CONFIG_H
@@ -547,8 +547,9 @@ again:
                if ((u_char *)ip + hlen <= snapend) {
                        sum = in_cksum((const u_short *)ip, hlen, 0);
                        if (sum != 0) {
-                               (void)printf("%sbad cksum %x!", sep,
-                                            ntohs(ip->ip_sum));
+                               (void)printf("%sbad cksum %x (->%x)!", sep,
+                                            ntohs(ip->ip_sum),
+                                            ntohs(ip->ip_sum)-sum);
                                sep = ", ";
                        }
                }