summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorenami <enami>2015-01-20 08:29:22 +0000
committerenami <enami>2015-01-20 08:29:22 +0000
commit6542149d5d40712c3e50ae72b169765feb3e711a (patch)
tree9e1de88d999b7f2dc547eaaa8600a769c60e8a3a
parent45d43266134680d95db4d5b42f19c33eb3a87bdc (diff)
downloadpkgsrc-6542149d5d40712c3e50ae72b169765feb3e711a.tar.gz
Fix owin calculation on 64bit machine. These subtraction must be done
in 32bit always.
-rw-r--r--net/tcptrace/distinfo3
-rw-r--r--net/tcptrace/patches/patch-trace.c19
2 files changed, 21 insertions, 1 deletions
diff --git a/net/tcptrace/distinfo b/net/tcptrace/distinfo
index a43ccb5efa7..6ba8e10c2a1 100644
--- a/net/tcptrace/distinfo
+++ b/net/tcptrace/distinfo
@@ -1,4 +1,4 @@
-$NetBSD: distinfo,v 1.9 2015/01/20 00:04:58 enami Exp $
+$NetBSD: distinfo,v 1.10 2015/01/20 08:29:22 enami Exp $
SHA1 (tcptrace-6.6.7.tar.gz) = ae4d10a0829c57f2eda17e63f593e558f52b7f24
RMD160 (tcptrace-6.6.7.tar.gz) = 1dd0f373f766322343ffad59d0655eba4c6682e0
@@ -8,3 +8,4 @@ SHA1 (patch-filt__parser.y) = ac7c510d6bf231496e9c6b459c7a97d98531dbaf
SHA1 (patch-filter.c) = 3058ee8b08ceca99b38ae772b51d26df91de6d9c
SHA1 (patch-filter.h) = 6e8170f63938e4e3b2c8c97ea9361d707af2f8bb
SHA1 (patch-tcpdump.c) = 4079d257814d966aca2c290fc131bef82ad15fe2
+SHA1 (patch-trace.c) = 9a373fb586526301804cac283abda8031a15df0d
diff --git a/net/tcptrace/patches/patch-trace.c b/net/tcptrace/patches/patch-trace.c
new file mode 100644
index 00000000000..aa8093a56fd
--- /dev/null
+++ b/net/tcptrace/patches/patch-trace.c
@@ -0,0 +1,19 @@
+$NetBSD: patch-trace.c,v 1.1 2015/01/20 08:29:22 enami Exp $
+
+--- trace.c.orig 2015-01-20 08:06:47.000000000 +0000
++++ trace.c
+@@ -2416,12 +2416,12 @@ dotrace(
+ * bytes in this pkt.
+ */
+ if (otherdir->ack == 0){
+- owin = end - start ;
++ owin = (seqnum)end - (seqnum)start;
+ }
+ else {
+ /* ack always acks 'received + 1' bytes, so subtract 1
+ * for owin */
+- owin = end - (otherdir->ack - 1);
++ owin = (seqnum)end - (otherdir->ack - 1);
+ }
+
+ if (owin > thisdir->owin_max)