summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authormillert <millert@openbsd.org>2000-03-23 19:13:51 +0000
committermillert <millert@openbsd.org>2000-03-23 19:13:51 +0000
commit86c8b537cb810d3203b0dc1d43b531d143d79fc2 (patch)
treeed34b6b3490d4d997206e9caf5b2648752237be1
parentIiieeek! This kludge was almost funny. (diff)
downloadwireguard-openbsd-86c8b537cb810d3203b0dc1d43b531d143d79fc2.tar.xz
wireguard-openbsd-86c8b537cb810d3203b0dc1d43b531d143d79fc2.zip
Add #ifdef __STDC__ around the rangematch function header to avoid
promotion of test to int, thus violating the prototype. Gcc handles this gracefully but more std ANSI compilers will complain.
-rw-r--r--lib/libc/gen/fnmatch.c10
1 files changed, 7 insertions, 3 deletions
diff --git a/lib/libc/gen/fnmatch.c b/lib/libc/gen/fnmatch.c
index acb6047b7fd..3424488af79 100644
--- a/lib/libc/gen/fnmatch.c
+++ b/lib/libc/gen/fnmatch.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: fnmatch.c,v 1.6 1998/03/19 00:29:59 millert Exp $ */
+/* $OpenBSD: fnmatch.c,v 1.7 2000/03/23 19:13:51 millert Exp $ */
/*
* Copyright (c) 1989, 1993, 1994
@@ -40,7 +40,7 @@
#if 0
static char sccsid[] = "@(#)fnmatch.c 8.2 (Berkeley) 4/16/94";
#else
-static char rcsid[] = "$OpenBSD: fnmatch.c,v 1.6 1998/03/19 00:29:59 millert Exp $";
+static char rcsid[] = "$OpenBSD: fnmatch.c,v 1.7 2000/03/23 19:13:51 millert Exp $";
#endif
#endif /* LIBC_SCCS and not lint */
@@ -165,11 +165,15 @@ fnmatch(pattern, string, flags)
}
static int
+#ifdef __STDC__
+rangematch(const char *pattern, char test, int flags, char **newp)
+#else
rangematch(pattern, test, flags, newp)
- const char *pattern;
+ char *pattern;
char test;
int flags;
char **newp;
+#endif
{
int negate, ok;
char c, c2;