diff options
| author | fukachan <fukachan> | 2001-04-08 06:13:15 +0000 |
|---|---|---|
| committer | fukachan <fukachan> | 2001-04-08 06:13:15 +0000 |
| commit | 32154676e4528f67d79e65c521812b12978bb707 (patch) | |
| tree | e7c0c9aa13b953580a4134d1bfadf0bb50cc11b1 | |
| parent | bbd8b48f80335d698839c2c1c04ce1112ba2cd3c (diff) | |
| download | fml8-32154676e4528f67d79e65c521812b12978bb707.tar.gz fml8-32154676e4528f67d79e65c521812b12978bb707.tar.bz2 fml8-32154676e4528f67d79e65c521812b12978bb707.zip | |
a new $curproc format: $curproc->{ xxx }->{ message } is a reference
to a chain of Mail::Message objects.
This modification comes from the change of our parser.
See Mail::Message class (1.8-1.9) for on Mail::Message->parse().
| -rw-r--r-- | fml/lib/FML/Process/Distribute.pm | 13 | ||||
| -rw-r--r-- | fml/lib/FML/Process/Kernel.pm | 11 |
2 files changed, 14 insertions, 10 deletions
diff --git a/fml/lib/FML/Process/Distribute.pm b/fml/lib/FML/Process/Distribute.pm index 835add20..dc574170 100644 --- a/fml/lib/FML/Process/Distribute.pm +++ b/fml/lib/FML/Process/Distribute.pm @@ -4,7 +4,7 @@ # Copyright (C) 2000 Ken'ichi Fukamachi # All rights reserved. # -# $FML: Distribute.pm,v 1.40 2001/04/03 09:45:43 fukachan Exp $ +# $FML: Distribute.pm,v 1.41 2001/04/06 16:25:43 fukachan Exp $ # package FML::Process::Distribute; @@ -250,9 +250,10 @@ sub _deliver_article { my ($curproc, $args) = @_; - my $config = $curproc->{ config }; # FML::Config obj - my $body = $curproc->{ article }->{ body }; # Mail::Message obj - my $header = $curproc->{ article }->{ header };# FML::Header obj + my $config = $curproc->{ config }; # FML::Config object + my $message = $curproc->{ article }->{ message }; # Mail::Message object + my $header = $curproc->{ article }->{ header }; # FML::Header object + my $body = $curproc->{ article }->{ body }; # Mail::Message object unless ( $config->yes( 'use_article_delivery' ) ) { return; @@ -287,6 +288,7 @@ sub _deliver_article } } + # start delivery my $service = new Mail::Delivery { log_function => $fp, smtp_log_function => $sfp, @@ -301,8 +303,7 @@ sub _deliver_article 'recipient_maps' => $config->{recipient_maps}, 'recipient_limit' => $config->{recipient_limit}, - 'header' => $header, - 'body' => $body, + 'message' => $message, }); if ($service->error) { Log($service->error); return;} } diff --git a/fml/lib/FML/Process/Kernel.pm b/fml/lib/FML/Process/Kernel.pm index 6f554733..47c74807 100644 --- a/fml/lib/FML/Process/Kernel.pm +++ b/fml/lib/FML/Process/Kernel.pm @@ -5,7 +5,7 @@ # redistribute it and/or modify it under the same terms as Perl itself. # # $Id$ -# $FML$ +# $FML: Kernel.pm,v 1.39 2001/04/03 09:45:43 fukachan Exp $ # package FML::Process::Kernel; @@ -411,9 +411,12 @@ sub parse_incoming_message # malloc the incoming message on memory. # $r_msg is the reference to the memory area. - my $r_msg = {}; - ($r_msg->{'header'}, $r_msg->{'body'}) = new FML::Parse $curproc, \*STDIN; - $curproc->{'incoming_message'} = $r_msg; + my $msg = new FML::Parse $curproc, \*STDIN; + + # store the message to $curproc + $curproc->{ incoming_message }->{ message } = $msg; + $curproc->{ incoming_message }->{ header } = $msg->rfc822_message_header; + $curproc->{ incoming_message }->{ body } = $msg->rfc822_message_body; } |
