From e138416d9e5d5f5202ab25505ff9bac94e9adbe0 Mon Sep 17 00:00:00 2001 From: Paul Eggert Date: Fri, 8 Jul 2005 17:57:01 +0000 Subject: [PATCH] * config/srclist.txt: Comment out regcomp.c, since we have a porting fix now. * lib/regcomp.c (init_dfa, build_range_exp): Store __btowc value in wint_t, not wchar_t. Remove now-unnecessary cast. --- config/ChangeLog | 5 +++++ config/srclist.txt | 7 ++++--- lib/ChangeLog | 6 ++++++ lib/regcomp.c | 7 ++++--- 4 files changed, 19 insertions(+), 6 deletions(-) diff --git a/config/ChangeLog b/config/ChangeLog index 79cfdcf6ef..16ceb4b789 100644 --- a/config/ChangeLog +++ b/config/ChangeLog @@ -1,3 +1,8 @@ +2005-07-08 Paul Eggert + + * srclist.txt: Comment out regcomp.c, since we have a porting fix + now. + 2005-07-07 Paul Eggert * srclist.txt: Add regcomp.c, regex.c, regex.h, regex_internal.c, diff --git a/config/srclist.txt b/config/srclist.txt index 52ec0af0b7..c1b88676e2 100644 --- a/config/srclist.txt +++ b/config/srclist.txt @@ -1,4 +1,4 @@ -# $Id: srclist.txt,v 1.65 2005-07-07 08:08:39 eggert Exp $ +# $Id: srclist.txt,v 1.66 2005-07-08 17:57:01 eggert Exp $ # Files for which we are not the source. See ./srclistvars.sh for the # variable definitions. @@ -93,11 +93,12 @@ $LIBCSRC/stdlib/getsubopt.c lib gpl #$LIBCSRC/posix/getopt.h lib gpl (getopt_.h in gnulib) #$LIBCSRC/posix/getopt1.c lib gpl #$LIBCSRC/posix/getopt_int.h lib gpl -$LIBCSRC/posix/regcomp.c lib gpl +# regcomp.c contains a porting fix +#$LIBCSRC/posix/regcomp.c lib gpl $LIBCSRC/posix/regex.c lib gpl $LIBCSRC/posix/regex.h lib gpl $LIBCSRC/posix/regex_internal.c lib gpl -# regex_internal.h contains a porting fix (glibc defines __mempcpy) +# regex_internal.h contains a porting fix #$LIBCSRC/posix/regex_internal.h lib gpl $LIBCSRC/posix/regexec.c lib gpl # c89 changes $LIBCSRC/string/strdup.c lib gpl diff --git a/lib/ChangeLog b/lib/ChangeLog index 168ceaa1be..eae3731984 100644 --- a/lib/ChangeLog +++ b/lib/ChangeLog @@ -1,3 +1,9 @@ +2005-07-08 Eric Blake (tiny change) + and Paul Eggert + + * regcomp.c (init_dfa, build_range_exp): Store __btowc value + in wint_t, not wchar_t. Remove now-unnecessary cast. + 2005-07-07 Paul Eggert * regex.c, regex.h: Sync from libc. diff --git a/lib/regcomp.c b/lib/regcomp.c index 9feac9fc45..ea93934055 100644 --- a/lib/regcomp.c +++ b/lib/regcomp.c @@ -917,11 +917,11 @@ init_dfa (dfa, pat_len) for (i = 0, ch = 0; i < BITSET_UINTS; ++i) for (j = 0; j < UINT_BITS; ++j, ++ch) { - wchar_t wch = __btowc (ch); + wint_t wch = __btowc (ch); if (wch != WEOF) dfa->sb_char[i] |= 1 << j; # ifndef _LIBC - if (isascii (ch) && wch != (wchar_t) ch) + if (isascii (ch) && wch != ch) dfa->map_notascii = 1; # endif } @@ -2682,7 +2682,8 @@ build_range_exp (sbcset, start_elem, end_elem) # ifdef RE_ENABLE_I18N { - wchar_t wc, start_wc, end_wc; + wchar_t wc; + wint_t start_wc, end_wc; wchar_t cmp_buf[6] = {L'\0', L'\0', L'\0', L'\0', L'\0', L'\0'}; start_ch = ((start_elem->type == SB_CHAR) ? start_elem->opr.ch -- 2.30.2