Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 13 Dec 2006 23:29:25 +0100 (CET)
From:      Richard Arends <richard@unixguru.nl>
To:        FreeBSD-gnats-submit@FreeBSD.org
Subject:   ports/106693: Update tcpdstat so it can be compiled with GCC 4.*
Message-ID:  <20061213222925.9723C56471@mail.unixguru.nl>
Resent-Message-ID: <200612132230.kBDMU5BW076201@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help

>Number:         106693
>Category:       ports
>Synopsis:       Update tcpdstat so it can be compiled with GCC 4.*
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          maintainer-update
>Submitter-Id:   current-users
>Arrival-Date:   Wed Dec 13 22:30:04 GMT 2006
>Closed-Date:
>Last-Modified:
>Originator:     Richard Arends
>Release:        FreeBSD 7.0-CURRENT i386
>Organization:
>Environment:
System: FreeBSD fbsd_current.unixguru.nl 7.0-CURRENT FreeBSD 7.0-CURRENT #1: Wed Dec 13 21:36:53 CET 2006     root@fbsd_current.unixguru.nl:/usr/obj/usr/src/sys/GENERIC  i386


>Description:
	tcpdstat can not be build with GCC 4.* 
>How-To-Repeat:
	cd /usr/ports/net/tcpdstat && make
>Fix:
	Apply the following patch

diff -ruN tcpdstat.orig/files/patch-net_read.c tcpdstat/files/patch-net_read.c
--- tcpdstat.orig/files/patch-net_read.c	Thu Jan  1 01:00:00 1970
+++ tcpdstat/files/patch-net_read.c	Wed Dec 13 23:20:33 2006
@@ -0,0 +1,11 @@
+--- net_read.orig	Wed Dec 13 23:11:59 2006
++++ net_read.c	Wed Dec 13 23:12:17 2006
+@@ -137,7 +137,7 @@
+ pcap_t *pd;
+ int pcapfd;
+ 
+-static int packet_length;		/* length of current packet */
++int packet_length;		/* length of current packet */
+ 
+ #define STAT_ADD(name) \
+     { tcpdstat[(name)].packets++; tcpdstat[(name)].bytes += packet_length; }
>Release-Note:
>Audit-Trail:
>Unformatted:



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20061213222925.9723C56471>