Gentoo Archives: gentoo-commits

From: Jeroen Roovers <jer@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: net-analyzer/hping/files/, net-analyzer/hping/
Date: Mon, 17 Apr 2017 05:59:40
Message-Id: 1492408760.bdf91376c408d86d3c177b2a5e5a8a10a6551b80.jer@gentoo
1 commit: bdf91376c408d86d3c177b2a5e5a8a10a6551b80
2 Author: Jeroen Roovers <jer <AT> gentoo <DOT> org>
3 AuthorDate: Mon Apr 17 05:59:20 2017 +0000
4 Commit: Jeroen Roovers <jer <AT> gentoo <DOT> org>
5 CommitDate: Mon Apr 17 05:59:20 2017 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=bdf91376
7
8 net-analyzer/hping: Fix memset issue in ip_opt_build().
9
10 Package-Manager: Portage-2.3.5, Repoman-2.3.2
11
12 .../hping/files/hping-3_pre20051105-strlen.patch | 11 +++++++
13 ...105-r5.ebuild => hping-3_pre20051105-r6.ebuild} | 34 +++++++++++++---------
14 2 files changed, 31 insertions(+), 14 deletions(-)
15
16 diff --git a/net-analyzer/hping/files/hping-3_pre20051105-strlen.patch b/net-analyzer/hping/files/hping-3_pre20051105-strlen.patch
17 new file mode 100644
18 index 00000000000..692cd93102f
19 --- /dev/null
20 +++ b/net-analyzer/hping/files/hping-3_pre20051105-strlen.patch
21 @@ -0,0 +1,11 @@
22 +--- a/ip_opt_build.c
23 ++++ b/ip_opt_build.c
24 +@@ -25,7 +25,7 @@
25 + unsigned char optlen = 0;
26 + unsigned long ip;
27 +
28 +- memset(ip_opt, 1, sizeof(ip_opt));
29 ++ memset(ip_opt, 1, strlen(ip_opt));
30 +
31 + if (opt_lsrr)
32 + {
33
34 diff --git a/net-analyzer/hping/hping-3_pre20051105-r5.ebuild b/net-analyzer/hping/hping-3_pre20051105-r6.ebuild
35 similarity index 73%
36 rename from net-analyzer/hping/hping-3_pre20051105-r5.ebuild
37 rename to net-analyzer/hping/hping-3_pre20051105-r6.ebuild
38 index 8f8890ed829..b173af1353b 100644
39 --- a/net-analyzer/hping/hping-3_pre20051105-r5.ebuild
40 +++ b/net-analyzer/hping/hping-3_pre20051105-r6.ebuild
41 @@ -1,8 +1,7 @@
42 -# Copyright 1999-2015 Gentoo Foundation
43 +# Copyright 1999-2017 Gentoo Foundation
44 # Distributed under the terms of the GNU General Public License v2
45
46 -EAPI=5
47 -
48 +EAPI=6
49 inherit eutils multilib toolchain-funcs
50
51 MY_P="${PN}${PV//_pre/-}"
52 @@ -17,19 +16,26 @@ IUSE="tcl"
53
54 S="${WORKDIR}/${MY_P}"
55
56 -DEPEND="net-libs/libpcap
57 - tcl? ( dev-lang/tcl:0= )"
58 -RDEPEND="${DEPEND}"
59 +DEPEND="
60 + net-libs/libpcap
61 + tcl? ( dev-lang/tcl:0= )
62 +"
63 +RDEPEND="
64 + ${DEPEND}
65 +"
66 +PATCHES=(
67 + "${FILESDIR}"/${P}.patch
68 + "${FILESDIR}"/bytesex.h.patch
69 + "${FILESDIR}"/${P}-tcl.patch
70 + "${FILESDIR}"/${P}-ldflags.patch
71 + "${FILESDIR}"/${P}-libtcl.patch
72 + "${FILESDIR}"/${P}-scan-overflow.patch
73 + "${FILESDIR}"/${P}-tclsh-proper-escaping.patch
74 + "${FILESDIR}"/${P}-strlen.patch
75 +)
76
77 src_prepare() {
78 - epatch \
79 - "${FILESDIR}"/${P}.patch \
80 - "${FILESDIR}"/bytesex.h.patch \
81 - "${FILESDIR}"/${P}-tcl.patch \
82 - "${FILESDIR}"/${P}-ldflags.patch \
83 - "${FILESDIR}"/${P}-libtcl.patch \
84 - "${FILESDIR}"/${P}-scan-overflow.patch \
85 - "${FILESDIR}"/${P}-tclsh-proper-escaping.patch # bug #486664
86 + default
87
88 # Correct hard coded values
89 sed -i Makefile.in \