Click here to get back home

patch for Mail::SendEasy

 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
patch for Mail::SendEasy Yakov 03-14-2007
Posted by Yakov on March 14, 2007, 3:01 am
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

Posted by Peter J. Holzer on March 14, 2007, 5:28 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
Mail::SendEasy smtp error, July 21, 2005, 1:56 pm
Mail::SendEasy defaulting to localhost? March 27, 2006, 4:41 am
submitting patch to perl docs March 18, 2007, 5:40 pm
Bug in perl v5.8.5 Built for sun4-solaris. Any patch availabale? January 27, 2005, 6:21 am
Using Mail::IMAPClient and Mail::Folder together June 2, 2005, 9:57 pm
Sending mail through Mail::Outlook May 25, 2006, 12:22 pm
ESS labels on ESMTP mail: perhaps using Net::Server::Mail::ESMTP April 17, 2007, 11:58 am
MAIL recommendation October 25, 2004, 1:10 am
mail forwarding October 28, 2004, 2:17 pm
FAQ 9.20: How do I send mail? November 9, 2004, 12:03 pm

Our other projects:

Art Dolls, Fairies and Mermaids - Sunnyfaces.net

Roy's Linux, Programming and Search Engines messages

1-Script XML SitemapXML Sitemap