X-Git-Url: https://git.saurik.com/apple/libc.git/blobdiff_plain/3d9156a7a519a5e3aa1b92e9d9d4b991f1aed7ff..6990d062918770ee2431fb3310826c5aefbffccd:/regex/FreeBSD/regexec.c diff --git a/regex/FreeBSD/regexec.c b/regex/FreeBSD/regexec.c index c570369..4bc04ae 100644 --- a/regex/FreeBSD/regexec.c +++ b/regex/FreeBSD/regexec.c @@ -14,10 +14,6 @@ * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. - * 3. All advertising materials mentioning features or use of this software - * must display the following acknowledgement: - * This product includes software developed by the University of - * California, Berkeley and its contributors. * 4. Neither the name of the University nor the names of its contributors * may be used to endorse or promote products derived from this software * without specific prior written permission. @@ -41,7 +37,7 @@ static char sccsid[] = "@(#)regexec.c 8.3 (Berkeley) 3/20/94"; #endif /* LIBC_SCCS and not lint */ #include -__FBSDID("$FreeBSD: src/lib/libc/regex/regexec.c,v 1.6 2004/07/12 07:35:59 tjr Exp $"); +__FBSDID("$FreeBSD: src/lib/libc/regex/regexec.c,v 1.8 2007/06/11 03:05:54 delphij Exp $"); /* * the outer shell of regexec() @@ -66,12 +62,7 @@ __FBSDID("$FreeBSD: src/lib/libc/regex/regexec.c,v 1.6 2004/07/12 07:35:59 tjr E static int nope __unused = 0; /* for use in asserts; shuts lint up */ static __inline size_t -xmbrtowc(wi, s, n, mbs, dummy) -wint_t *wi; -const char *s; -size_t n; -mbstate_t *mbs; -wint_t dummy; +xmbrtowc(wint_t *wi, const char *s, size_t n, mbstate_t *mbs, wint_t dummy) { size_t nr; wchar_t wc; @@ -91,12 +82,11 @@ wint_t dummy; } static __inline size_t -xmbrtowc_dummy(wi, s, n, mbs, dummy) -wint_t *wi; -const char *s; -size_t n __unused; -mbstate_t *mbs __unused; -wint_t dummy __unused; +xmbrtowc_dummy(wint_t *wi, + const char *s, + size_t n __unused, + mbstate_t *mbs __unused, + wint_t dummy __unused) { if (wi != NULL) @@ -214,12 +204,11 @@ wint_t dummy __unused; * have been prototyped. */ int /* 0 success, REG_NOMATCH failure */ -regexec(preg, string, nmatch, pmatch, eflags) -const regex_t * __restrict preg; -const char * __restrict string; -size_t nmatch; -regmatch_t pmatch[__restrict]; -int eflags; +regexec(const regex_t * __restrict preg, + const char * __restrict string, + size_t nmatch, + regmatch_t pmatch[__restrict], + int eflags) { struct re_guts *g = preg->re_g; #ifdef REDEBUG