[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
'restrict' fixes for regex.h, regcomp.c
From: |
Paul Eggert |
Subject: |
'restrict' fixes for regex.h, regcomp.c |
Date: |
Wed, 24 Aug 2005 22:22:21 -0700 |
User-agent: |
Gnus/5.1007 (Gnus v5.10.7) Emacs/21.4 (gnu/linux) |
I installed this to patch another POSIX incompatibility with regex,
and filed glibc bug 1240.
2005-08-24 Paul Eggert <address@hidden>
* config/srclist.txt: Add glibc bug 1240.
* lib/regcomp.c (regerror): 2nd arg is 'restrict', as per POSIX.
* lib/regex.h (regerror): Likewise.
--- config/srclist.txt 24 Aug 2005 23:43:00 -0000 1.84
+++ config/srclist.txt 25 Aug 2005 05:07:52 -0000
@@ -100,6 +100,7 @@ $LIBCSRC/stdlib/getsubopt.c lib gpl
# http://sources.redhat.com/bugzilla/show_bug.cgi?id=1223
# http://sources.redhat.com/bugzilla/show_bug.cgi?id=1224
# http://sources.redhat.com/bugzilla/show_bug.cgi?id=1237
+# http://sources.redhat.com/bugzilla/show_bug.cgi?id=1240
#$LIBCSRC/posix/regcomp.c lib gpl
#
# http://sources.redhat.com/bugzilla/show_bug.cgi?id=1238
@@ -110,6 +111,7 @@ $LIBCSRC/stdlib/getsubopt.c lib gpl
# http://sources.redhat.com/bugzilla/show_bug.cgi?id=1222
# http://sources.redhat.com/bugzilla/show_bug.cgi?id=1232
# http://sources.redhat.com/bugzilla/show_bug.cgi?id=1236
+# http://sources.redhat.com/bugzilla/show_bug.cgi?id=1240
#$LIBCSRC/posix/regex.h lib gpl
#
# http://sources.redhat.com/bugzilla/show_bug.cgi?id=1215
--- lib/regcomp.c 24 Aug 2005 23:29:39 -0000 1.7
+++ lib/regcomp.c 25 Aug 2005 05:07:52 -0000
@@ -496,7 +496,8 @@ weak_alias (__regcomp, regcomp)
from either regcomp or regexec. We don't use PREG here. */
size_t
-regerror (int errcode, const regex_t *preg, char *errbuf, size_t errbuf_size)
+regerror (int errcode, const regex_t *__restrict preg,
+ char *__restrict errbuf, size_t errbuf_size)
{
const char *msg;
size_t msg_size;
--- lib/regex.h 24 Aug 2005 23:09:33 -0000 1.32
+++ lib/regex.h 25 Aug 2005 05:07:52 -0000
@@ -614,8 +614,8 @@ extern int regexec (const regex_t *__res
regmatch_t __pmatch[__restrict_arr],
int __eflags);
-extern size_t regerror (int __errcode, const regex_t *__preg,
- char *__errbuf, size_t __errbuf_size);
+extern size_t regerror (int __errcode, const regex_t *__restrict __preg,
+ char *__restrict __errbuf, size_t __errbuf_size);
extern void regfree (regex_t *__preg);
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- 'restrict' fixes for regex.h, regcomp.c,
Paul Eggert <=