From: Gerard Goossen Date: Thu, 27 Mar 2008 13:55:31 +0000 (+0100) Subject: MAD dump xml escape regex X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=643e696a61334e453a6ab25a83a9625db27387ac;p=p5sagit%2Fp5-mst-13.2.git MAD dump xml escape regex Message-ID: <20080327125531.GN4409@ostwald> p4raw-id: //depot/perl@33584 --- diff --git a/dump.c b/dump.c index 7ad09b1..37337bb 100644 --- a/dump.c +++ b/dump.c @@ -2534,8 +2534,8 @@ Perl_do_pmop_xmldump(pTHX_ I32 level, PerlIO *file, const PMOP *pm) level++; if (PM_GETRE(pm)) { REGEXP *const r = PM_GETRE(pm); - SV * const tmpsv = newSVsv((SV*)r); - sv_utf8_upgrade(tmpsv); + SV * const tmpsv = newSVpvn_utf8("", 0, TRUE); + sv_catxmlsv(tmpsv, (SV*)r); Perl_xmldump_indent(aTHX_ level, file, "pre=\"%s\"\n", SvPVX(tmpsv)); SvREFCNT_dec(tmpsv); diff --git a/mad/t/p55.t b/mad/t/p55.t index e1f3523..fcfa032 100644 --- a/mad/t/p55.t +++ b/mad/t/p55.t @@ -75,30 +75,10 @@ our %failing = map { $_, 1 } qw| ../t/op/exec.t ../t/io/say.t -../t/io/open.t -../t/op/gv.t -../t/op/re.t -../t/op/tr.t -../t/op/die.t -../t/op/pat.t -../t/op/reg_namedcapture.t -../t/op/reg_email.t -../t/op/reg_nc_tie.t -../t/op/utf8decode.t ../t/op/state.t -../t/op/subst.t -../t/op/goto.t ../t/op/tiehandle.t -../t/op/pack.t ../t/op/each_array.t -../t/op/sprintf.t -../t/op/attrs.t -../t/op/universal.t -../t/op/regexp.t ../t/lib/cygwin.t -../t/run/switchd.t -../t/comp/proto.t -../t/win32/system.t |; my @files;