Great Circle Associates Majordomo-Users
(May 1997)
 

Indexed By Date: [Previous] [Next] Indexed By Thread: [Previous] [Next]

Subject: RE: archive2.pl and EOL
From: Peter Bostrom <pbostrom @ morino . org>
Date: Mon, 5 May 1997 13:41:46 -0400
To: "'Christopher Adams'" <chris @ sparkie . osl . state . or . us>
Cc: "'majordomo-users @ greatcircle . com'" <majordomo-users @ GreatCircle . COM>

Peter Bostrom wrote:
PB> What would cause my MS Exchange users' 
PB> messages to generate archive entries that frequently 
PB> (though not constantly) end in an '=20' or simply '=' 
PB> when they are written out.

PB> The message(s) are text/plain, i.e., no fancy content
PB> types. I'm stumped, help.

And Christopher Adams pointed out:
CA> This is not a Majordomo problem. 

Well, I wouldn't go so far as to say that. Seems to me that
MJ ought to be able - in it's infinite wisdom, and in the interests
of cross-platform peace and prosperity - to solve such a trivial
issue.

CA> It has to do with the format of the 
CA> message text and the hard returns or EOL characters. Different platforms 
CA> (Mac,PC,Unix) handle EOL characters differently. I believe (though am not 
CA> sure), different mailers will handle text from a variety of formats 
CA> differently, and will result in this problem. I don't have a solution 
CA> though.

Which would leave sendmail itself as the culprit, is that what you are
saying?  I haven't had a chance to dig far enough into the problem to
determine if these EOL characters are appearing there or not. I will say
that I haven't noticed over the last couple of years that this problem 
appeared in anything other than the Majordomo archives, in the latest
incarnation as well as others going back to early 1.9x version of MJ.

The problem gets immediately magnified when I run Hypermail against
the message archive, in essence perpetuating the ugliness of the client
and mailer's inability to co-exist.

Here's a not very subtle fix, appreciate a better technique if anyone has
any suggestions . . .

# mjstrip -
#
#   routine to strip trailing equal signs and
#   other garbage off of the end of Majordomo archive
#   files.
#
# USAGE:
#
#   $ ./mjstrip <input-file> <output-file>
#
#   Peter Bostrom,
#   The Morino Institute
#   May 2, 1997
#

$archive = $ARGV[0];
$outfile = $ARGV[1];

$outfile = "$outfile";
$infile = "$archive";

print "   Stripping . . . " . $archive . "\n";

open (FILE, "$infile");
open (OUT, ">$outfile");

while(<FILE>) {
     #get rid of \n
     chop($_);
     #substitute ends with 0-9 and = to nothing, and vice versa
     $_=~s/=[0-9][0-9]$//;
     $_=~s/=[0-9]$//;
     $_=~s/=$//;
     # now print the clean line out with the \n
     print OUT $_ . "\n";
}

close (FILE);
close (OUT);

exit 0;



Follow-Ups:
Indexed By Date Previous: Re: archive2.pl and EOL
From: Christopher Adams <chris@sparkie.osl.state.or.us>
Next: Re: MS Exchange users (was archive2.pl and EOL)
From: "Milam, Charles R. 1LT CAP" <cmilam@cap.af.mil>
Indexed By Thread Previous: Re: archive2.pl and EOL
From: Christopher Adams <chris@sparkie.osl.state.or.us>
Next: Re: archive2.pl and EOL
From: Rich Pieri <rich.pieri@prescienttech.com>

Google
 
Search Internet Search www.greatcircle.com