Click here to get back home

i want to share my secrets with u.........

 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
i want to share my secrets with u......... aquorang 01-03-2008
Get Chitika Premium
Posted by aquorang on January 3, 2008, 11:54 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
Online Poker Pays! Learn All The Secrets Now!NBP Unregistered. October 30, 2005, 3:25 am
Threading - share August 27, 2006, 3:15 pm
share winlyrics to wmp SMI in perl August 31, 2004, 3:25 am
share a session between two website April 29, 2006, 8:59 am
OOP: Share objects between classes June 11, 2006, 5:47 pm
FTP to a windows file share? October 18, 2006, 8:15 am
Share objects between processes - how? April 20, 2007, 4:13 am
Accessing SMB share on Mac OSX for file copy March 2, 2005, 4:08 pm
File-Find and Samba share June 16, 2005, 6:50 am
Creating a WIN32 folder share August 24, 2005, 3:47 am

Our other projects:

Art Dolls, Fairies and Mermaids - Sunnyfaces.net

Roy's Linux, Programming and Search Engines messages

1-Script XML SitemapXML Sitemap