In perl.git, the branch blead has been updated <http://perl5.git.perl.org/perl.git/commitdiff/215c5139cb98a8536a622f8aaace5a0b808475a7?hp=613abc6d16e99bd9834fe6afd79beb61a3a4734d>
- Log ----------------------------------------------------------------- commit 215c5139cb98a8536a622f8aaace5a0b808475a7 Author: Karl Williamson <[email protected]> Date: Tue Dec 30 02:27:42 2014 +0100 Fix breakage of 780fcc9 I got confused in writing this: the global needs to be cleared always, and set to NULL. M locale.c commit ec5e0e1c1f697116bf6df6bbcc70ed40e5690123 Author: Karl Williamson <[email protected]> Date: Mon Dec 29 18:39:40 2014 -0700 regexec.c: Suppress warning messages A message on some compilers is geing generated that two variables may be unininitialized. In fact there is no path through that uses them thusly, but initialize them anyway where the compiler is wrong. M regexec.c ----------------------------------------------------------------------- Summary of changes: locale.c | 9 +++++++-- regexec.c | 2 ++ 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/locale.c b/locale.c index 2577ed2..8fec798 100644 --- a/locale.c +++ b/locale.c @@ -272,6 +272,13 @@ Perl_new_ctype(pTHX_ const char *newctype) PERL_ARGS_ASSERT_NEW_CTYPE; + /* We will replace any bad locale warning with 1) nothing if the new one is + * ok; or 2) a new warning for the bad new locale */ + if (PL_warn_locale) { + SvREFCNT_dec_NN(PL_warn_locale); + PL_warn_locale = NULL; + } + PL_in_utf8_CTYPE_locale = _is_cur_LC_category_utf8(LC_CTYPE); /* A UTF-8 locale gets standard rules. But note that code still has to @@ -292,8 +299,6 @@ Perl_new_ctype(pTHX_ const char *newctype) to start */ unsigned int bad_count = 0; /* Count of bad characters */ - SvREFCNT_dec(PL_warn_locale); /* We are about to overwrite this */ - for (i = 0; i < 256; i++) { if (isUPPER_LC((U8) i)) PL_fold_locale[i] = (U8) toLOWER_LC((U8) i); diff --git a/regexec.c b/regexec.c index e659f4b..5b8565c 100644 --- a/regexec.c +++ b/regexec.c @@ -4591,6 +4591,8 @@ S_regmatch(pTHX_ regmatch_info *reginfo, char *startpos, regnode *prog) } fold_utf8_flags = FOLDEQ_LOCALE | FOLDEQ_S1_ALREADY_FOLDED | FOLDEQ_S1_FOLDS_SANE; + folder = foldEQ_latin1; + fold_array = PL_fold_latin1; goto do_exactf; case EXACTFU_SS: /* /\x{df}/iu */ -- Perl5 Master Repository
