Change 33147 by [EMAIL PROTECTED] on 2008/01/31 11:07:48
Integrate:
[ 32866]
Fix a bug in mad - regexps can be 8 bit, not just ASCII or UTF-8.
[but differently for 5.10, as regexps aren't first class]
Affected files ...
... //depot/maint-5.10/perl/dump.c#4 integrate
Differences ...
==== //depot/maint-5.10/perl/dump.c#4 (text) ====
Index: perl/dump.c
--- perl/dump.c#3~33146~ 2008-01-31 02:45:59.000000000 -0800
+++ perl/dump.c 2008-01-31 03:07:48.000000000 -0800
@@ -2453,9 +2453,9 @@
level++;
if (PM_GETRE(pm)) {
REGEXP *const r = PM_GETRE(pm);
- /* FIXME ORANGE - REGEXP can be 8 bit, so this is sometimes buggy: */
- SV * const tmpsv = newSVpvn(RX_PRECOMP(r),RX_PRELEN(r));
- SvUTF8_on(tmpsv);
+ SV * const tmpsv
+ = newSVpvn_utf8(RX_PRECOMP(r), RX_PRELEN(r), RX_UTF8(r));
+ sv_utf8_upgrade(tmpsv);
Perl_xmldump_indent(aTHX_ level, file, "pre=\"%s\"\n",
SvPVX(tmpsv));
SvREFCNT_dec(tmpsv);
End of Patch.