aboutsummaryrefslogtreecommitdiff
path: root/sbin/ipf/libipf/ipft_hx.c
diff options
context:
space:
mode:
authorCy Schubert <cy@FreeBSD.org>2021-12-20 17:07:20 +0000
committerCy Schubert <cy@FreeBSD.org>2022-01-04 02:06:42 +0000
commitefeb8bffe34422937c7f8df836afb5b817366d16 (patch)
tree488c0bccb66ed43ceb0c87ec6c6c386f70ab4179 /sbin/ipf/libipf/ipft_hx.c
parent064a5a95649d05ac084bcf2612cbac5575d76358 (diff)
downloadsrc-efeb8bffe34422937c7f8df836afb5b817366d16.tar.gz
src-efeb8bffe34422937c7f8df836afb5b817366d16.zip
ipflter: ANSIfy userland function declarations
Convert ipfilter userland function declarations from K&R to ANSI. This syncs our function declarations with NetBSD hg commit 75edcd7552a0 (apply our changes). Though not copied from NetBSD, this change was partially inspired by NetBSD's work and inspired by style(9). Reviewed by: glebius (for #network) MFC after: 1 month Differential Revision: https://reviews.freebsd.org/D33595
Diffstat (limited to 'sbin/ipf/libipf/ipft_hx.c')
-rw-r--r--sbin/ipf/libipf/ipft_hx.c17
1 files changed, 8 insertions, 9 deletions
diff --git a/sbin/ipf/libipf/ipft_hx.c b/sbin/ipf/libipf/ipft_hx.c
index e424c3929c79..8b27ddd33bd6 100644
--- a/sbin/ipf/libipf/ipft_hx.c
+++ b/sbin/ipf/libipf/ipft_hx.c
@@ -27,8 +27,8 @@ struct ipread iphex = { hex_open, hex_close, hex_readip, 0 };
static FILE *tfp = NULL;
static int tfd = -1;
-static int hex_open(fname)
- char *fname;
+static int
+hex_open(char *fname)
{
if (tfp && tfd != -1) {
rewind(tfp);
@@ -47,7 +47,8 @@ static int hex_open(fname)
}
-static int hex_close()
+static int
+hex_close(void)
{
int cfd = tfd;
@@ -56,10 +57,8 @@ static int hex_close()
}
-static int hex_readip(mb, ifn, dir)
- mb_t *mb;
- char **ifn;
- int *dir;
+static int
+hex_readip(mb_t *mb, char **ifn, int *dir)
{
register char *s, *t, *u;
char line[513];
@@ -153,8 +152,8 @@ static int hex_readip(mb, ifn, dir)
}
-static char *readhex(src, dst)
-register char *src, *dst;
+static char
+*readhex(register char *src, register char *dst)
{
int state = 0;
char c;