Skip Menu |
 

This queue is for tickets about the Encode CPAN distribution.

Report information
The Basics
Id: 70719
Status: resolved
Priority: 0/
Queue: Encode

People
Owner: Nobody in particular
Requestors: perlbug-followup [...] perl.org
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: (no value)
Fixed in: (no value)



From rt-sprout=cpan.org [...] rt.perl.org Sun Sep 4 13: 46:29 2011
CC: bug-Encode [...] rt.cpan.org
MIME-Version: 1.0
In-Reply-To: <5.14.1_25983_1315139128 [...] oz.intra.net>
X-Spam-Status: No, score=-7.407 tagged_above=-99.9 required=10 tests=[AWL=-0.507, BAYES_00=-1.9, RCVD_IN_DNSWL_HI=-5] autolearn=ham
X-Spam-Flag: NO
References: <RT-Ticket-98370 [...] perl.org> <5.14.1_25983_1315139128 [...] oz.intra.net>
Content-Type: text/plain; charset="utf-8"
Message-ID: <rt-3.6.HEAD-31297-1315158380-1312.98370-15-0 [...] perl.org>
Reply-To: perlbug-followup [...] perl.org
X-Virus-Scanned: Debian amavisd-new at bestpractical.com
X-RT-Original-Encoding: utf-8
RT-Originator: sprout [...] cpan.org
X-Spam-Score: -7.407
Managed-BY: RT 3.6.HEAD (http://www.bestpractical.com/rt/)
Received: from localhost (localhost [127.0.0.1]) by hipster.bestpractical.com (Postfix) with ESMTP id F1B0524084E for <cpan-bug+Encode [...] hipster.bestpractical.com>; Sun, 4 Sep 2011 13:46:28 -0400 (EDT)
Received: from hipster.bestpractical.com ([127.0.0.1]) by localhost (hipster.bestpractical.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id W4vzn7bAo7OA for <cpan-bug+Encode [...] hipster.bestpractical.com>; Sun, 4 Sep 2011 13:46:27 -0400 (EDT)
Received: from la.mx.develooper.com (x1.develooper.com [207.171.7.70]) by hipster.bestpractical.com (Postfix) with SMTP id 44FBC2401BE for <bug-Encode [...] rt.cpan.org>; Sun, 4 Sep 2011 13:46:27 -0400 (EDT)
Received: (qmail 18184 invoked by uid 103); 4 Sep 2011 17:46:26 -0000
Received: from x16.dev (10.0.100.26) by x1.dev with QMQP; 4 Sep 2011 17:46:26 -0000
Received: from x17.develooper.com (HELO x17.develooper.com) (207.171.7.217) by 16.mx.develooper.com (qpsmtpd/0.80/v0.80-19-gf52d165) with ESMTP; Sun, 04 Sep 2011 10:46:24 -0700
Received: by x17.develooper.com (Postfix, from userid 405) id BCFFF35BD0; Sun, 4 Sep 2011 10:46:21 -0700 (PDT)
Delivered-To: cpan-bug+Encode [...] hipster.bestpractical.com
Subject: [perl #98370] Perl doesn't decode IBM037
Return-Path: <rt-sprout=cpan.org [...] rt.perl.org>
X-RT-Mail-Extension: encode
X-Original-To: cpan-bug+Encode [...] hipster.bestpractical.com
X-Spam-Check-BY: 16.mx.develooper.com
Date: Sun, 04 Sep 2011 10:46:21 -0700
RT-Ticket: perl #98370
X-Spam-Level:
Precedence: normal
To: "OtherRecipients of perl Ticket #98370":;
X-RT-Loop-Prevention: perl
Content-Transfer-Encoding: 8bit
From: "Father Chrysostomos via RT" <perlbug-followup [...] perl.org>
Content-Length: 4485
Download (untitled) / with headers
text/plain 4.3k
Forwarding to the CPAN queue.... On Sun Sep 04 06:05:20 2011, tomushkin@gmail.com wrote: Show quoted text
> > > This is a bug report for perl from tomushkin@gmail.com, > generated with the help of perlbug 1.39 running under perl 5.14.1. > > > ----------------------------------------------------------------- > [Please describe your issue here] > > # perl -MEncode -e 'decode("IBM037", "\x{a2}\x{97}\x{81}\x{94}")' > Unknown encoding 'IBM037' at -e line 1 > > My servers are spammed with IBM037 encoded email, that renders > properly by the most mail clients, but fails to decode by the > perl filters. For some reason, it doesn't alias to cp37, but > cp037. I use the following workaround: > > use Encode::Alias; > define_alias(qr/^cp0+(\d+)$/i => ''"cp$1"''); > > [Please do not change anything below this line] > ----------------------------------------------------------------- > --- > Flags: > category=library > severity=low > module=Encode > --- > Site configuration information for perl 5.14.1: > > Configured by nobody at Wed Jun 29 17:15:04 UTC 2011. > > Summary of my perl5 (revision 5 version 14 subversion 1) > configuration: > > Platform: > osname=linux, osvers=2.6.39-arch, archname=x86_64-linux-thread- > multi > uname='linux foutbox 2.6.39-arch #1 smp preempt mon jun 27 > 21:26:22 cest 2011 x86_64 amd phenom(tm) ii x6 1090t processor > authenticamd gnulinux ' > config_args='-des -Dusethreads -Duseshrplib > -Doptimize=-march=x86-64 -mtune=generic -O2 -pipe -Dprefix=/usr > -Dinstallprefix=/usr -Dvendorprefix=/usr > -Dprivlib=/usr/share/perl5/core_perl > -Darchlib=/usr/lib/perl5/core_perl > -Dsitelib=/usr/share/perl5/site_perl > -Dsitearch=/usr/lib/perl5/site_perl > -Dvendorlib=/usr/share/perl5/vendor_perl > -Dvendorarch=/usr/lib/perl5/vendor_perl > -Dscriptdir=/usr/bin/core_perl -Dsitescript=/usr/bin/site_perl > -Dvendorscript=/usr/bin/vendor_perl -Dinc_version_list=none > -Dman1ext=1perl -Dman3ext=3perl -Dcccdlflags='-fPIC' > -Dlddlflags=-shared -Wl,--hash-style=gnu -Wl,--as-needed > -Dldflags=-Wl,--hash-style=gnu -Wl,--as-needed' > hint=recommended, useposix=true, d_sigaction=define > useithreads=define, usemultiplicity=define > useperlio=define, d_sfio=undef, uselargefiles=define, > usesocks=undef > use64bitint=define, use64bitall=define, uselongdouble=undef > usemymalloc=n, bincompat5005=undef > Compiler: > cc='cc', ccflags ='-D_REENTRANT -D_GNU_SOURCE -fno-strict-aliasing > -pipe -fstack-protector -I/usr/local/include -D_LARGEFILE_SOURCE > -D_FILE_OFFSET_BITS=64', > optimize='-march=x86-64 -mtune=generic -O2 -pipe', > cppflags='-D_REENTRANT -D_GNU_SOURCE -fno-strict-aliasing -pipe > -fstack-protector -I/usr/local/include' > ccversion='', gccversion='4.6.1', gccosandvers='' > intsize=4, longsize=8, ptrsize=8, doublesize=8, byteorder=12345678 > d_longlong=define, longlongsize=8, d_longdbl=define, > longdblsize=16 > ivtype='long', ivsize=8, nvtype='double', nvsize=8, Off_t='off_t', > lseeksize=8 > alignbytes=8, prototype=define > Linker and Libraries: > ld='cc', ldflags ='-Wl,--hash-style=gnu -Wl,--as-needed > -fstack-protector -L/usr/local/lib' > libpth=/usr/local/lib /lib/../lib /usr/lib/../lib /lib /usr/lib > libs=-lnsl -lgdbm -ldb -ldl -lm -lcrypt -lutil -lpthread -lc > -lgdbm_compat > perllibs=-lnsl -ldl -lm -lcrypt -lutil -lpthread -lc > libc=/lib/libc-2.14.so, so=so, useshrplib=true, libperl=libperl.so > gnulibc_version='2.14' > Dynamic Linking: > dlsrc=dl_dlopen.xs, dlext=so, d_dlsymun=undef, ccdlflags='-Wl,-E > -Wl,-rpath,/usr/lib/perl5/core_perl/CORE' > cccdlflags='-fPIC', lddlflags='-shared -Wl,--hash-style=gnu > -Wl,--as-needed -L/usr/local/lib -fstack-protector' > > Locally applied patches: > > > --- > @INC for perl 5.14.1: > /usr/lib/perl5/site_perl > /usr/share/perl5/site_perl > /usr/lib/perl5/vendor_perl > /usr/share/perl5/vendor_perl > /usr/lib/perl5/core_perl > /usr/share/perl5/core_perl > . > > --- > Environment for perl 5.14.1: > HOME=/home/toma > LANG=en_US.UTF-8 > LANGUAGE (unset) > LC_ALL=en_US.UTF-8 > LD_LIBRARY_PATH= > LOGDIR (unset) >
PATH=/usr/local/bin:/usr/bin:/bin:/usr/games:/opt/java/jre/bin:/usr/bin/vendor_perl:/usr/lib/perl5/vendor_perl/bin:/usr/bin/core_perl Show quoted text
> PERL5LIB= > PERL_BADLANG (unset) > SHELL=/bin/zsh
MIME-Version: 1.0
In-Reply-To: <rt-3.6.HEAD-31297-1315158380-1312.98370-15-0 [...] perl.org>
X-Mailer: MIME-tools 5.427 (Entity 5.427)
Content-Disposition: inline
References: <RT-Ticket-98370 [...] perl.org> <5.14.1_25983_1315139128 [...] oz.intra.net> <rt-3.6.HEAD-31297-1315158380-1312.98370-15-0 [...] perl.org>
Content-Type: text/plain; charset="UTF-8"
Message-ID: <rt-3.8.HEAD-11168-1344205447-139.70719-0-0 [...] rt.cpan.org>
Content-Transfer-Encoding: binary
X-RT-Original-Encoding: utf-8
Content-Length: 5010
Download (untitled) / with headers
text/plain 4.8k
iconv does not recognize IBM037 either. So consider that a feature, or lack thereof. FYI use Encode::Alias; define_alias(qr/^IBM0+(\d+)$/i => ''"cp$1"''); should do the trick you asked for. Dan the Maintainer Thereof On Sun Sep 04 13:46:29 2011, perlbug-followup@perl.org wrote: Show quoted text
> Forwarding to the CPAN queue.... > > On Sun Sep 04 06:05:20 2011, tomushkin@gmail.com wrote:
> > > > > > This is a bug report for perl from tomushkin@gmail.com, > > generated with the help of perlbug 1.39 running under perl 5.14.1. > > > > > > ----------------------------------------------------------------- > > [Please describe your issue here] > > > > # perl -MEncode -e 'decode("IBM037", "\x{a2}\x{97}\x{81}\x{94}")' > > Unknown encoding 'IBM037' at -e line 1 > > > > My servers are spammed with IBM037 encoded email, that renders > > properly by the most mail clients, but fails to decode by the > > perl filters. For some reason, it doesn't alias to cp37, but > > cp037. I use the following workaround: > > > > use Encode::Alias; > > define_alias(qr/^cp0+(\d+)$/i => ''"cp$1"''); > > > > [Please do not change anything below this line] > > ----------------------------------------------------------------- > > --- > > Flags: > > category=library > > severity=low > > module=Encode > > --- > > Site configuration information for perl 5.14.1: > > > > Configured by nobody at Wed Jun 29 17:15:04 UTC 2011. > > > > Summary of my perl5 (revision 5 version 14 subversion 1) > > configuration: > > > > Platform: > > osname=linux, osvers=2.6.39-arch, archname=x86_64-linux-thread- > > multi > > uname='linux foutbox 2.6.39-arch #1 smp preempt mon jun 27 > > 21:26:22 cest 2011 x86_64 amd phenom(tm) ii x6 1090t processor > > authenticamd gnulinux ' > > config_args='-des -Dusethreads -Duseshrplib > > -Doptimize=-march=x86-64 -mtune=generic -O2 -pipe -Dprefix=/usr > > -Dinstallprefix=/usr -Dvendorprefix=/usr > > -Dprivlib=/usr/share/perl5/core_perl > > -Darchlib=/usr/lib/perl5/core_perl > > -Dsitelib=/usr/share/perl5/site_perl > > -Dsitearch=/usr/lib/perl5/site_perl > > -Dvendorlib=/usr/share/perl5/vendor_perl > > -Dvendorarch=/usr/lib/perl5/vendor_perl > > -Dscriptdir=/usr/bin/core_perl -Dsitescript=/usr/bin/site_perl > > -Dvendorscript=/usr/bin/vendor_perl -Dinc_version_list=none > > -Dman1ext=1perl -Dman3ext=3perl -Dcccdlflags='-fPIC' > > -Dlddlflags=-shared -Wl,--hash-style=gnu -Wl,--as-needed > > -Dldflags=-Wl,--hash-style=gnu -Wl,--as-needed' > > hint=recommended, useposix=true, d_sigaction=define > > useithreads=define, usemultiplicity=define > > useperlio=define, d_sfio=undef, uselargefiles=define, > > usesocks=undef > > use64bitint=define, use64bitall=define, uselongdouble=undef > > usemymalloc=n, bincompat5005=undef > > Compiler: > > cc='cc', ccflags ='-D_REENTRANT -D_GNU_SOURCE
> -fno-strict-aliasing
> > -pipe -fstack-protector -I/usr/local/include -D_LARGEFILE_SOURCE > > -D_FILE_OFFSET_BITS=64', > > optimize='-march=x86-64 -mtune=generic -O2 -pipe', > > cppflags='-D_REENTRANT -D_GNU_SOURCE -fno-strict-aliasing -pipe > > -fstack-protector -I/usr/local/include' > > ccversion='', gccversion='4.6.1', gccosandvers='' > > intsize=4, longsize=8, ptrsize=8, doublesize=8,
> byteorder=12345678
> > d_longlong=define, longlongsize=8, d_longdbl=define, > > longdblsize=16 > > ivtype='long', ivsize=8, nvtype='double', nvsize=8,
> Off_t='off_t',
> > lseeksize=8 > > alignbytes=8, prototype=define > > Linker and Libraries: > > ld='cc', ldflags ='-Wl,--hash-style=gnu -Wl,--as-needed > > -fstack-protector -L/usr/local/lib' > > libpth=/usr/local/lib /lib/../lib /usr/lib/../lib /lib /usr/lib > > libs=-lnsl -lgdbm -ldb -ldl -lm -lcrypt -lutil -lpthread -lc > > -lgdbm_compat > > perllibs=-lnsl -ldl -lm -lcrypt -lutil -lpthread -lc > > libc=/lib/libc-2.14.so, so=so, useshrplib=true,
> libperl=libperl.so
> > gnulibc_version='2.14' > > Dynamic Linking: > > dlsrc=dl_dlopen.xs, dlext=so, d_dlsymun=undef, ccdlflags='-Wl,-E > > -Wl,-rpath,/usr/lib/perl5/core_perl/CORE' > > cccdlflags='-fPIC', lddlflags='-shared -Wl,--hash-style=gnu > > -Wl,--as-needed -L/usr/local/lib -fstack-protector' > > > > Locally applied patches: > > > > > > --- > > @INC for perl 5.14.1: > > /usr/lib/perl5/site_perl > > /usr/share/perl5/site_perl > > /usr/lib/perl5/vendor_perl > > /usr/share/perl5/vendor_perl > > /usr/lib/perl5/core_perl > > /usr/share/perl5/core_perl > > . > > > > --- > > Environment for perl 5.14.1: > > HOME=/home/toma > > LANG=en_US.UTF-8 > > LANGUAGE (unset) > > LC_ALL=en_US.UTF-8 > > LD_LIBRARY_PATH= > > LOGDIR (unset) > >
>
PATH=/usr/local/bin:/usr/bin:/bin:/usr/games:/opt/java/jre/bin:/usr/bin/vendor_perl:/usr/lib /perl5/vendor_perl/bin:/usr/bin/core_perl Show quoted text
> > PERL5LIB= > > PERL_BADLANG (unset) > > SHELL=/bin/zsh
> > >


This service is sponsored and maintained by Best Practical Solutions and runs on Perl.org infrastructure.

Please report any issues with rt.cpan.org to rt-cpan-admin@bestpractical.com.