From 0690ee732ae01493bc6b5c053808f79c22882a91 Mon Sep 17 00:00:00 2001 From: Kyle Evans Date: Sun, 29 Mar 2020 02:26:58 +0000 Subject: [PATCH] ipfilter: remove duplicate definition of 'thishost' thishost is already defined in lib/initparse.c; no need for this one. This fixes the ipfilter build with -fno-common. -fno-common will become the default in GCC10/LLVM11. MFC after: 3 days --- contrib/ipfilter/ipf.h | 2 +- contrib/ipfilter/tools/ipnat.c | 1 - 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/contrib/ipfilter/ipf.h b/contrib/ipfilter/ipf.h index f5617334a0ba..05dcfa4afd64 100644 --- a/contrib/ipfilter/ipf.h +++ b/contrib/ipfilter/ipf.h @@ -191,7 +191,7 @@ typedef int (* addfunc_t) __P((int, ioctlfunc_t, void *)); typedef int (* copyfunc_t) __P((void *, void *, size_t)); -extern char thishost[]; +extern char thishost[MAXHOSTNAMELEN]; extern char flagset[]; extern u_char flags[]; extern struct ipopt_names ionames[]; diff --git a/contrib/ipfilter/tools/ipnat.c b/contrib/ipfilter/tools/ipnat.c index 54a71653f3e2..7d76893cfd2c 100644 --- a/contrib/ipfilter/tools/ipnat.c +++ b/contrib/ipfilter/tools/ipnat.c @@ -60,7 +60,6 @@ static const char rcsid[] = "@(#)$Id$"; #define bzero(a,b) memset(a,0,b) #endif int use_inet6 = 0; -char thishost[MAXHOSTNAMELEN]; extern char *optarg;