At 15 Mar 2002 19:53:56 -0000,
Gerald Richter wrote:
> richter     02/03/15 11:53:56
>   Index: Mail.pm
>   ===================================================================
>   RCS file: /home/cvs/embperl/Embperl/Mail.pm,v
>   retrieving revision 1.29.4.4
>   retrieving revision 1.29.4.5
>   diff -u -r1.29.4.4 -r1.29.4.5
>   --- Mail.pm 22 Jan 2002 09:29:55 -0000      1.29.4.4
>   +++ Mail.pm 15 Mar 2002 19:53:56 -0000      1.29.4.5
>   @@ -68,8 +76,8 @@
>                                      ($helo?(Hello => $helo):()) 
>                                      ) or die "Cannot connect to mailhost 
>$req->{mailhost}" ;
>    
>   -        my $from =  $req -> {from} || $ENV{'EMBPERL_MAILFROM'} ;
>   -        $smtp->mail($from || "WWW-Server\@$ENV{SERVER_NAME}");
>   +        my $from =  $req -> {from} || $ENV{'EMBPERL_MAILFROM'} || 
>"WWW-Server\@$ENV{SERVER_NAME}" || 'localhost' ;
>   +        $smtp->mail($from);
>    
>            my $to ;
>            if (ref ($req -> {'to'}))

"WWW-Server\@$ENV{SERVER_NAME}" will never be false. you probably
wanted something like:

--- Mail.pm     22 Jan 2002 09:29:55 -0000      1.29.4.4
+++ Mail.pm     15 Mar 2002 19:53:56 -0000      1.29.4.5
@@ -68,8 +76,8 @@
                                   ($helo?(Hello => $helo):()) 
                                   ) or die "Cannot connect to mailhost 
$req->{mailhost}" ;
 
-        my $from =  $req -> {from} || $ENV{'EMBPERL_MAILFROM'} ;
-        $smtp->mail($from || "WWW-Server\@$ENV{SERVER_NAME}");
+        my $from =  $req -> {from} || $ENV{'EMBPERL_MAILFROM'} || 
+'WWW-Server\@'.($ENV{SERVER_NAME} || 'localhost') ;
+        $smtp->mail($from);
 
         my $to ;
         if (ref ($req -> {'to'}))

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to