This is the mail archive of the cygwin@cygwin.com mailing list for the Cygwin project.
Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
---|---|---|
Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |
Other format: | [Raw text] |
Hallo Rolf, Am Dienstag, 1. April 2003 um 18:13 schriebst du:Gerrit P. Haase wrote:Rolf schrieb:Ok, using PERLIO=perlio, but I'm still having a problem (which worked in the previous version of Perl).So, is this a cygwin perl problem? Or has the stock perl decided to only work with magic ENV variables?
I don't see the problem in the latest Perl (5.9.0) and I'm trying to figure out how it can be fixed, in the meantime, please try to use the magic PERLIO=perlio setting for your environment. Gerrit
TEST.PL: 1:#!/bin/perl 2:$/ = "\r\n"; 3: 4:open( LOG, "<in" ) || 5: die "Could not open log.\n"; 6:binmode LOG, ":crlf"; 7: 8:$in = <LOG>; 9:print $in;
in (od -c in): 0000000 a b c \r \n d e f \r \n 0000012
This is on a BINMODE mount. This script outputs "0000000 a b c \n d e f \n". If I go back to prev Perl, OR remove line#2 OR remove line#6, then it outputs "0000000 a b c \n"
1. No PERLIO setting:
$ od -c in 0000000 a b c \r \n a b c \r \n 0000012
$ ./crlf.pl 2>&1 | tee log.in abc abc
$ od -c log.in 0000000 a b c \r \n a b c \r \n 0000012
2. PERLIO=perlio:
$ export PERLIO=perlio
$ ./crlf.pl 2>&1 | tee log.in abc abc
$ od -c log.in 0000000 a b c \n a b c \n 0000010
3. PERLIO=raw:
$ export PERLIO=raw
$ ./crlf.pl 2>&1 | tee log.in abc abc
$ od -c log.in 0000000 a b c \n a b c \n 0000010
4. PERLIO=stdio:
$ export PERLIO=stdio
$ ./crlf.pl 2>&1 | tee log.in abc abc
$ od -c log.in 0000000 a b c \n a b c \n 0000010
5. PERLIO=:
$ export PERLIO=
$ ./crlf.pl 2>&1 | tee log.in abc abc
$ od -c log.in 0000000 a b c \r \n a b c \r \n 0000012
Gerrit
-- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Bug reporting: http://cygwin.com/bugs.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/
Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
---|---|---|
Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |