Subject: | chr should be ord in SVG::XML |
Date: | Sun, 22 Jul 2007 10:58:21 +0000 |
To: | bug-SVG-Parser [...] rt.cpan.org |
From: | "Debbie Harry" <hoglabogla [...] hotmail.com> |
chr should be ord in SVG::XML:xmlescp
sub xmlescp ($) {
...
$s=~s/([\x00-\x1f])/sprintf('&#x%02X;',chr($1))/eg;
should be:
$s=~s/([\x00-\x1f])/sprintf('&#x%02X;',ord($1))/eg;
$1 is the filtered "chr", you want to "ord" it, not "chr" it again.
Otherwhise files containing \x{a} can't be parsed
Cheers!
Show quoted text
_________________________________________________________________
Express yourself instantly with MSN Messenger! Download today it's FREE!
http://messenger.msn.click-url.com/go/onm00200471ave/direct/01/