Skip Menu |
 

This queue is for tickets about the Encode CPAN distribution.

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

People
Owner: Nobody in particular
Requestors: Gregory.Lepore [...] nara.gov
Cc:
AdminCc:

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



From Gregory.Lepore [...] nara.gov Thu Feb 16 09: 33:48 2012
MIME-Version: 1.0
X-Spam-Status: No, score=-4.398 tagged_above=-99.9 required=10 tests=[AWL=-2.498, BAYES_00=-1.9] autolearn=ham
X-Mailer: Novell GroupWise Internet Agent 8.0.2
Content-Disposition: inline
X-Spam-Flag: NO
Content-Type: text/plain; charset=UTF-8
Message-ID: <4F3CCD68020000AC0002893B [...] gwiaa.nara.gov>
X-Virus-Scanned: Debian amavisd-new at bestpractical.com
X-Spam-Score: -4.398
Received: from localhost (localhost [127.0.0.1]) by hipster.bestpractical.com (Postfix) with ESMTP id 170B52415C8 for <cpan-bug+Encode [...] hipster.bestpractical.com>; Thu, 16 Feb 2012 09:33:48 -0500 (EST)
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 BR2R3tuoemor for <cpan-bug+Encode [...] hipster.bestpractical.com>; Thu, 16 Feb 2012 09:33:42 -0500 (EST)
Received: from la.mx.develooper.com (x1.develooper.com [207.171.7.70]) by hipster.bestpractical.com (Postfix) with SMTP id F34C424153B for <bug-Encode [...] rt.cpan.org>; Thu, 16 Feb 2012 09:33:41 -0500 (EST)
Received: (qmail 22162 invoked by uid 103); 16 Feb 2012 14:33:41 -0000
Received: from x16.dev (10.0.100.26) by x1.dev with QMQP; 16 Feb 2012 14:33:41 -0000
Received: from gwiab.nara.gov (HELO gwiaa.nara.gov) (207.245.171.211) by 16.mx.develooper.com (qpsmtpd/0.80/v0.80-19-gf52d165) with ESMTP; Thu, 16 Feb 2012 06:33:35 -0800
Received: from GWIA1DOM-MTA by gwiaa.nara.gov with Novell_GroupWise; Thu, 16 Feb 2012 09:33:30 -0500
Delivered-To: cpan-bug+Encode [...] hipster.bestpractical.com
Subject: FB_DEFAULT endless loop
Return-Path: <Gregory.Lepore [...] nara.gov>
X-RT-Mail-Extension: encode
X-Original-To: cpan-bug+Encode [...] hipster.bestpractical.com
X-Spam-Check-BY: 16.mx.develooper.com
Date: Thu, 16 Feb 2012 09:33:28 -0500
X-Spam-Level:
To: <bug-Encode [...] rt.cpan.org>
Content-Transfer-Encoding: 8bit
From: "Gregory Lepore" <Gregory.Lepore [...] nara.gov>
X-RT-Original-Encoding: utf-8
Content-Length: 721
Download (untitled) / with headers
text/plain 721b
Bug identified on Perlmongs.org http://perlmonks.org/?node_id=953030 In theory, the following should work: use PerlIO::encoding; $PerlIO::encoding::fallback = Encode::FB_DEFAULT; However, when I try it, for example #!/usr/bin/perl use PerlIO::encoding; $PerlIO::encoding::fallback = Encode::FB_DEFAULT; open my $fh, "<:encoding(UTF-8)", $ARGV[0] or die $!; binmode STDOUT, ":encoding(UTF-8)"; while (<$fh>) { print } with an input file such as (where the 'ä' is Latin-1 encoded) foo bär although it does silence the warning, I do get an endless loop! Greg Lepore Information Technology Specialist National Archives at College Park 8601 Adelphi Road, Rm 5320 College Park, MD 20740 Tel. (301) 837-0758
MIME-Version: 1.0
In-Reply-To: <4F3CCD68020000AC0002893B [...] gwiaa.nara.gov>
X-Mailer: MIME-tools 5.427 (Entity 5.427)
Content-Disposition: inline
References: <4F3CCD68020000AC0002893B [...] gwiaa.nara.gov>
Content-Type: text/plain; charset="UTF-8"
Message-ID: <rt-3.8.HEAD-30586-1344206115-1165.75060-0-0 [...] rt.cpan.org>
Content-Transfer-Encoding: binary
X-RT-Original-Encoding: utf-8
Content-Length: 970
Download (untitled) / with headers
text/plain 970b
You should be careful when tweaking $PerlIO::encoding::fallback. See Encode::PerlIO for details. Dan the Maintainer Thereof On Thu Feb 16 09:33:48 2012, Gregory.Lepore@nara.gov wrote: Show quoted text
> Bug identified on Perlmongs.org > http://perlmonks.org/?node_id=953030 > > In theory, the following should work: > > use PerlIO::encoding; > $PerlIO::encoding::fallback = Encode::FB_DEFAULT; > > However, when I try it, for example > > #!/usr/bin/perl > use PerlIO::encoding; > $PerlIO::encoding::fallback = Encode::FB_DEFAULT; > open my $fh, "<:encoding(UTF-8)", $ARGV[0] or die $!; > binmode STDOUT, ":encoding(UTF-8)"; > while (<$fh>) { print } > > with an input file such as (where the 'ä' is Latin-1 encoded) > > foo > bär > > although it does silence the warning, I do get an endless loop! > > Greg Lepore > Information Technology Specialist > National Archives at College Park > 8601 Adelphi Road, Rm 5320 > College Park, MD 20740 > Tel. (301) 837-0758


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.