[dw-free] can't parse "ascii" encoding (really?!?)
[commit: http://hg.dwscoalition.org/dw-free/rev/13dce58a9cb7]
http://bugs.dwscoalition.org/show_bug.cgi?id=3817
Change "ascii" to "us-ascii" before passing off to XML parser.
Patch by
denise.
Files modified:
http://bugs.dwscoalition.org/show_bug.cgi?id=3817
Change "ascii" to "us-ascii" before passing off to XML parser.
Patch by
![[staff profile]](https://www.dreamwidth.org/img/silk/identity/user_staff.png)
Files modified:
- cgi-bin/LJ/SynSuck.pm
-------------------------------------------------------------------------------- diff -r fcc8dbfae4b2 -r 13dce58a9cb7 cgi-bin/LJ/SynSuck.pm --- a/cgi-bin/LJ/SynSuck.pm Mon Aug 22 10:38:24 2011 -0500 +++ b/cgi-bin/LJ/SynSuck.pm Mon Aug 22 10:51:20 2011 -0500 @@ -163,6 +163,11 @@ $content =~ s/encoding=([\"\'])(.+?)\1/encoding='us-ascii'/; } + # and yet another hack, this time to alias 'ascii' to 'us-ascii' + if ( $encoding =~ /^ascii$/i ) { + $content =~ s/encoding=([\"\'])(.+?)\1/encoding='us-ascii'/; + } + # parsing time... my ( $feed, $error ) = LJ::ParseFeed::parse_feed( $content ); return ( 0, { type => "parseerror", message => $error } ) if $error; --------------------------------------------------------------------------------
no subject
*snicker*