Subject: Perl gets \r in strings even in text mode
From: Reuben Thomas <[email-masked]>
To: [email-masked]
Date: Tue, 16 Oct 2001 14:09:01 +0100

I'm currently having problems with Perl returning strings with CRLFs in 
rather than just LFs, even when read in text mode, from a text-mode mount 
point.

For example, the following script:

#! /usr/bin/perl

while (<>) {
  if (m/\r\n/) { print "CRLF\n"; }
}

when saved to test.pl and run on a normal multi-line DOS text file prints 
"CRLF" lots of times, even when run on a DOS text file in a 
text-mode-mounted directory.

This is repeatable on different machines; I'm using cygwin-1.3.2-1 (not the 
latest, I know, but 1,3.3 has serious problems for me because of the 
segfault-triggered-by-recursive-make bug) and perl-5.6.1-2.

-- 
http://sc3d.org/rrt/ | Si hoc legere scis nimium eruditionis habes (Anon)

--
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/