summaryrefslogtreecommitdiffstats
path: root/lib/libc/regex/regcomp.c
diff options
context:
space:
mode:
authorguenther <guenther@openbsd.org>2020-10-13 04:42:28 +0000
committerguenther <guenther@openbsd.org>2020-10-13 04:42:28 +0000
commit036a3c97db0a437193eb7e0c8716ea40cb440a8b (patch)
tree43f3b08c3b3b6162602dfebfa98f9419e64cb223 /lib/libc/regex/regcomp.c
parentannoying whitespace gliches spotted during re-read (diff)
downloadwireguard-openbsd-036a3c97db0a437193eb7e0c8716ea40cb440a8b.tar.xz
wireguard-openbsd-036a3c97db0a437193eb7e0c8716ea40cb440a8b.zip
Do some easy .data -> .rodata/.data.rel.ro conversions
ok millert@ deraadt@
Diffstat (limited to 'lib/libc/regex/regcomp.c')
-rw-r--r--lib/libc/regex/regcomp.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/lib/libc/regex/regcomp.c b/lib/libc/regex/regcomp.c
index 3f2d46d0512..7396cf1dda5 100644
--- a/lib/libc/regex/regcomp.c
+++ b/lib/libc/regex/regcomp.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: regcomp.c,v 1.34 2019/02/05 20:57:30 millert Exp $ */
+/* $OpenBSD: regcomp.c,v 1.35 2020/10/13 04:42:28 guenther Exp $ */
/*-
* Copyright (c) 1992, 1993, 1994 Henry Spencer.
* Copyright (c) 1992, 1993, 1994
@@ -90,7 +90,7 @@ static void freeset(struct parse *, cset *);
static int freezeset(struct parse *, cset *);
static int firstch(struct parse *, cset *);
static int nch(struct parse *, cset *);
-static void mcadd(struct parse *, cset *, char *);
+static void mcadd(struct parse *, cset *, const char *);
static void mcinvert(struct parse *, cset *);
static void mccase(struct parse *, cset *);
static int isinsets(struct re_guts *, int);
@@ -762,9 +762,9 @@ static void
p_b_cclass(struct parse *p, cset *cs)
{
char *sp = p->next;
- struct cclass *cp;
+ const struct cclass *cp;
size_t len;
- char *u;
+ const char *u;
char c;
while (MORE() && isalpha((uch)PEEK()))
@@ -1177,7 +1177,7 @@ nch(struct parse *p, cset *cs)
- mcadd - add a collating element to a cset
*/
static void
-mcadd( struct parse *p, cset *cs, char *cp)
+mcadd( struct parse *p, cset *cs, const char *cp)
{
size_t oldend = cs->smultis;
void *np;