summaryrefslogtreecommitdiff
path: root/fml/lib
diff options
context:
space:
mode:
authorfukachan <fukachan>2004-05-16 12:25:59 +0000
committerfukachan <fukachan>2004-05-16 12:25:59 +0000
commit26f1bfcfae630e90903641e55c477703c80a44a8 (patch)
tree0c614c058e94e28a8083242e5d8e05f29faea938 /fml/lib
parent570a6c6897deab0a7c8a1aefe6c2f77dea32eae9 (diff)
downloadfml8-26f1bfcfae630e90903641e55c477703c80a44a8.tar.gz
fml8-26f1bfcfae630e90903641e55c477703c80a44a8.tar.bz2
fml8-26f1bfcfae630e90903641e55c477703c80a44a8.zip
define $MAP_ERR_OPEN.
log status of done or not (log only yet).
Diffstat (limited to 'fml/lib')
-rw-r--r--fml/lib/Mail/Delivery/SMTP.pm19
1 files changed, 18 insertions, 1 deletions
diff --git a/fml/lib/Mail/Delivery/SMTP.pm b/fml/lib/Mail/Delivery/SMTP.pm
index a8ea3b3b..50322035 100644
--- a/fml/lib/Mail/Delivery/SMTP.pm
+++ b/fml/lib/Mail/Delivery/SMTP.pm
@@ -4,7 +4,7 @@
# All rights reserved. This program is free software; you can
# redistribute it and/or modify it under the same terms as Perl itself.
#
-# $FML: SMTP.pm,v 1.27 2004/05/16 05:08:21 fukachan Exp $
+# $FML: SMTP.pm,v 1.28 2004/05/16 08:16:09 fukachan Exp $
#
@@ -24,6 +24,7 @@ END {}
# STATUS CODE
my $MAP_DONE = 'DONE';
my $MAP_NOT_DONE = 'NOT DONE';
+my $MAP_ERR_OPEN = 'CANNOT OPEN';
=head1 NAME
@@ -448,6 +449,7 @@ sub deliver
}
};
if ($@) {
+ $self->set_map_status($map, $MAP_ERR_OPEN);
Log("Error: cannot open and ignore $map");
next MAP;
}
@@ -511,6 +513,21 @@ sub deliver
}
}
+ # check map status.
+ MAP:
+ for my $map (@maps) {
+ my $status = $self->get_map_status($map);
+ next MAP if $status eq $MAP_ERR_OPEN;
+
+ unless ($self->get_map_status($map) eq $MAP_DONE) {
+ my $n = $self->get_map_position($map) || '?';
+ Log("map=$map pos=$n status=\"$status\"");
+
+ # XXX-TODO: fallback to queue
+ # dump todo into queue for later retry (may be by other process).
+ }
+ }
+
# clean up recipient_map information after "all delivery".
# CAUTION: this mapinfo tracks the delivery status.
$self->reset_mapinfo;