Ok, this is my best solution so far. I'm using open2. Now i get a response when i send a mail to a bad address (bad meaning the remote server is not accepting mail for the address given). This tested fine under RedHat 7.2.
sub SendMail{
my %MAIL = @_;
my $RESULT = "SendMail to".$MAIL{'TO'};
use IPC::Open2;
open2(*READA,*WRITEA,"/usr/lib/sendmail -oi -t");
print WRITEA "To:$MAIL{'TO'}\n";
print WRITEA "From:$MAIL{'FROM'}\n";
print WRITEA "Subject:$MAIL{'SUBJECT'}\n\n";
print WRITEA "$MAIL{'BODY'}\n";
close WRITEA;
while ($line = <READA>){$RESULT .= "<li>$line\n";}
close READA;
return $RESULT;
}############################ end SendMail
jtrue