mirror of
https://github.com/gentoo-mirror/gentoo.git
synced 2026-09-24 04:59:14 -07:00
net-misc/netstat-nat: fix modern C issues
Closes: https://bugs.gentoo.org/875149 Signed-off-by: Sam James <sam@gentoo.org>
This commit is contained in:
@@ -0,0 +1,9 @@
|
||||
--- a/Makefile.am
|
||||
+++ b/Makefile.am
|
||||
@@ -1,6 +1,5 @@
|
||||
bin_PROGRAMS = netstat-nat
|
||||
netstat_nat_SOURCES = netstat-nat.c netstat-nat.h
|
||||
-docdir = $(prefix)/share/doc/$(PACKAGE)-$(VERSION)
|
||||
doc_DATA = NEWS README ChangeLog AUTHORS
|
||||
dist_man_MANS = netstat-nat.1
|
||||
EXTRA_DIST = netstat-nat.spec
|
||||
13
net-misc/netstat-nat/files/netstat-nat-1.4.10-modern-c.patch
Normal file
13
net-misc/netstat-nat/files/netstat-nat-1.4.10-modern-c.patch
Normal file
@@ -0,0 +1,13 @@
|
||||
https://bugs.gentoo.org/875149
|
||||
--- a/netstat-nat.h
|
||||
+++ b/netstat-nat.h
|
||||
@@ -64,6 +64,9 @@ void ip_addresses_add(struct _ip_addresses **list, const char *dev, const char *
|
||||
int ip_addresses_search(struct _ip_addresses *list, const char *ip);
|
||||
void ip_addresses_free(struct _ip_addresses **list);
|
||||
|
||||
+int string_search(char *string, char *search);
|
||||
+int search_first_hit(char *search, char *line, char *ret);
|
||||
+int search_sec_hit(char *search, char *line, char *ret);
|
||||
|
||||
#define strcopy(dst, dst_size, src) \
|
||||
strncpy(dst, src, (dst_size - 1));
|
||||
@@ -1,7 +1,7 @@
|
||||
# Copyright 1999-2021 Gentoo Authors
|
||||
# Copyright 1999-2023 Gentoo Authors
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
|
||||
EAPI=7
|
||||
EAPI=8
|
||||
|
||||
inherit autotools
|
||||
|
||||
@@ -15,6 +15,8 @@ KEYWORDS="amd64 ~arm ppc sparc x86"
|
||||
|
||||
PATCHES=(
|
||||
"${FILESDIR}"/${P}-install.patch
|
||||
"${FILESDIR}"/${P}-modern-c.patch
|
||||
"${FILESDIR}"/${P}-docdir.patch
|
||||
)
|
||||
|
||||
src_prepare() {
|
||||
Reference in New Issue
Block a user