--- cgi-bin/getmsg.pl 2000/04/19 06:08:53 1.2 +++ cgi-bin/getmsg.pl 2000/04/19 10:27:53 1.3 @@ -265,7 +265,8 @@ #the browser will chop it off. #This is unlikely, but we want to cover any #eventuality. - foreach ($pop->Head($i)) { + my @headers=$pop->Head($i); + while ($_ = shift @headers) { #parse out the From line from the header. #Also, remove any angle brackets @@ -291,7 +292,7 @@ $replyto = $'; $replyto =~ s/\s+//; #remove intervening white space $replyto =~ s/\/>\;/; + $replyto =~ s/\>/>\;/; } @@ -334,8 +335,14 @@ # $' PERL system function. $to = $'; $to =~ s/\s+//; #remove leading white space - $to =~ s/\/>\;/; + #support for multi-line To: + while ($headers[0] =~ m/^ +/) { + my $tmp = shift @headers; + $tmp =~ s/\s+//; + $to .= $tmp; + } + $to =~ s/\/>\;/g; } #parse out the recipient line. @@ -346,7 +353,7 @@ $cc = $'; $cc =~ s/\s+//; #remove leading white space $cc =~ s/\/>\;/; + $cc =~ s/\>/>\;/; } }