Click here to get back home

Mac OS X Update -> module's man in /

 HomeNewsGroups | Search | About
 comp.lang.perl.misc    Post an article   get this group's latest topics as an RSS feed add this group's latest topics to your My MSN content add this group's latest topics to your My Yahoo content
Subject Author Date
Mac OS X Update -> module's man in / Martin Kissner 02-12-2005
Posted by Martin Kissner on February 12, 2005, 12:56 pm
Please log in for more thread options
>>
>> [snip]
>>
>> > if I print "$1\n",
>> > the file prints just fine. But, if I do something like print "$1 after
>> > \n", the whole output is messed up. If I print "before $1\n", nothing
>> > prints at all. If I print "before $1 after\n", only after prints.
>>
>> not really sure, but could be a rogue "\r" in $1,


> There
> is a rogue carriage return (0xd) in the string

> Is there something I can do to deal with this
> situation?


Repair the corrupted file:

perl -p -i -e 'tr/\r//d' bad_file


--
Tad McClellan SGML consulting
tadmc@augustmail.com Perl programming
Fort Worth, Texas

Similar ThreadsPosted
Mac OS X Update -> module's man in / February 12, 2005, 1:28 pm
Finding a module's $VERSION programmatically October 30, 2004, 1:27 pm
How to find a module's path on a server November 10, 2005, 6:10 am
Preventing changes to a module's variables in mod_perl September 14, 2006, 2:55 pm
How to use a module's @EXPORT array to document its exported objects? July 19, 2006, 12:52 pm
My Regexp XML Parser -> Structured Perl Data, Cut & Paste Version, No Module's (Vol I) December 20, 2005, 11:59 pm
DBI update April 14, 2005, 11:32 pm
UPDATE DB September 5, 2007, 4:26 pm
dynamic update February 26, 2005, 4:09 pm
LWP gives 302 Found after update? August 16, 2005, 6:05 pm

Our other projects:

Art Dolls, Fairies and Mermaids - Sunnyfaces.net

Roy's Linux, Programming and Search Engines messages

1-Script XML SitemapXML Sitemap