let print_filter_to_entries_fn =
|fe: &Rc<RefCell<FEntry>>,
parser: &mut Parser,
- se: &SEntry,
- dstatus: Option<DStatus>| {
- let mut dstatus = match dstatus {
- Some(d) => d,
- None => DStatus::Invalid,
- };
+ se: &SEntry| {
for to in fe.borrow().to_entries.iter().rev() {
- if dstatus == DStatus::Invalid {
- dstatus = to.dstatus;
- }
parser.write_all_ok(format!(
"TO:{:X}:T{:08X}L{:08X}:{}: from <",
- to.timestamp as i32, se.timestamp as i32, se.rel_line_nr, dstatus,
+ to.timestamp as i32, se.timestamp as i32, se.rel_line_nr, to.dstatus,
));
parser.write_all_ok(&se.bq_from);
parser.write_all_ok(b"> to <");
if let Some(fe) = &self.filter() {
// limited to !fe.is_accepted because otherwise we would have
// a QEntry with all required information instead
- if fe.borrow().is_bq && !fe.borrow().is_accepted && self.is_bq_accepted {
- print_filter_to_entries_fn(&fe, parser, self, None);
- } else if fe.borrow().is_bq && !fe.borrow().is_accepted && self.is_bq_rejected {
- print_filter_to_entries_fn(&fe, parser, self, Some(DStatus::Noqueue));
+ if fe.borrow().is_bq && !fe.borrow().is_accepted && (self.is_bq_accepted || self.is_bq_rejected) {
+ print_filter_to_entries_fn(&fe, parser, self);
}
}
SMTPD: T5FDCC4EFL00000000
CTIME: 5FDCC4EF
CLIENT: pmg.localhost[192.168.22.40]
-TO:5FDCC4EF:T5FDCC4EFL00000000:N: from <mailtestsender2@localhost.localdomain> to <pmgtest@localhost.localdomain>
+TO:5FDCC4EF:T5FDCC4EFL00000000:B: from <mailtestsender2@localhost.localdomain> to <pmgtest@localhost.localdomain>
LOGS:
L00000002 Dec 18 15:04:15 pmg postfix/smtpd[21842]: connect from pmg.localhost[192.168.22.40]
L00000003 Dec 18 15:04:15 pmg postfix/smtpd[21842]: NOQUEUE: client=pmg.localhost[192.168.22.40]
SMTPD: T5FDCC4EFL00000000
CTIME: 5FDCC4EF
CLIENT: pmg.localhost[192.168.22.40]
-TO:5FDCC4EF:T5FDCC4EFL00000000:N: from <mailtestsender2@localhost.localdomain> to <pmgtest@localhost.localdomain>
+TO:5FDCC4EF:T5FDCC4EFL00000000:B: from <mailtestsender2@localhost.localdomain> to <pmgtest@localhost.localdomain>
LOGS:
L00000002 Dec 18 15:04:15 pmg postfix/smtpd[21842]: connect from pmg.localhost[192.168.22.40]
L00000003 Dec 18 15:04:15 pmg postfix/smtpd[21842]: NOQUEUE: client=pmg.localhost[192.168.22.40]
SMTPD: T5FDCC4EFL00000000
CTIME: 5FDCC4EF
CLIENT: pmg.localhost[192.168.22.40]
-TO:5FDCC4EF:T5FDCC4EFL00000000:N: from <mailtestsender2@localhost.localdomain> to <pmgtest@localhost.localdomain>
+TO:5FDCC4EF:T5FDCC4EFL00000000:B: from <mailtestsender2@localhost.localdomain> to <pmgtest@localhost.localdomain>
LOGS:
L00000002 Dec 18 15:04:15 pmg postfix/smtpd[21842]: connect from pmg.localhost[192.168.22.40]
L00000003 Dec 18 15:04:15 pmg postfix/smtpd[21842]: NOQUEUE: client=pmg.localhost[192.168.22.40]