Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/usr.bin/netstat Use ptrdiff_t to hold pointer difference to ...



details:   https://anonhg.NetBSD.org/src/rev/df9c9c21179a
branches:  trunk
changeset: 764868:df9c9c21179a
user:      enami <enami%NetBSD.org@localhost>
date:      Tue May 10 04:40:16 2011 +0000

description:
Use ptrdiff_t to hold pointer difference to avoid coredump on LP64 system.

diffstat:

 usr.bin/netstat/vtw.c |  8 ++++----
 1 files changed, 4 insertions(+), 4 deletions(-)

diffs (36 lines):

diff -r 5006def3e4c4 -r df9c9c21179a usr.bin/netstat/vtw.c
--- a/usr.bin/netstat/vtw.c     Tue May 10 01:58:58 2011 +0000
+++ b/usr.bin/netstat/vtw.c     Tue May 10 04:40:16 2011 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: vtw.c,v 1.4 2011/05/04 03:43:30 pgoyette Exp $ */
+/*     $NetBSD: vtw.c,v 1.5 2011/05/10 04:40:16 enami Exp $    */
 
 /*
  * Copyright (c) 2011 The NetBSD Foundation, Inc.
@@ -62,7 +62,7 @@
 #if 0
 static char sccsid[] = "from: @(#)inet.c       8.4 (Berkeley) 4/20/94";
 #else
-__RCSID("$NetBSD: vtw.c,v 1.4 2011/05/04 03:43:30 pgoyette Exp $");
+__RCSID("$NetBSD: vtw.c,v 1.5 2011/05/10 04:40:16 enami Exp $");
 #endif
 #endif /* not lint */
 
@@ -251,7 +251,7 @@
        for (i = 0; i < VTW_NCLASS; ++i) {
                vtw_v4_t *kbase, *klim;
                vtw_v4_t *ubase, *ulim;
-               int delta;
+               ptrdiff_t delta;
 
                kbase = vtw_tcpv4[i].base.v4;
                klim = vtw_tcpv4[i].lim.v4;
@@ -354,7 +354,7 @@
        for (i = 0; i < VTW_NCLASS; ++i) {
                vtw_v6_t *kbase, *klim;
                vtw_v6_t *ubase, *ulim;
-               int delta;
+               ptrdiff_t delta;
 
                kbase = vtw_tcpv6[i].base.v6;
                klim = vtw_tcpv6[i].lim.v6;



Home | Main Index | Thread Index | Old Index