[PATCH] temp_resolver_failed is a transaction note

[email protected] ("Peter J. Holzer")
Newsgroups perl.qpsmtpd
Message-ID <[email protected]>
 The mail hook sets a transaction note 'temp_resolver_failed', but the
 rcpt hook queried a connection note of the same name (which didn't
 exist, of course).
 Now it queries the transaction note.

---
 plugins/require_resolvable_fromhost |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/plugins/require_resolvable_fromhost b/plugins/require_resolvable_fromhost
index e9e2a91..cdb1890 100644
--- a/plugins/require_resolvable_fromhost
+++ b/plugins/require_resolvable_fromhost
@@ -41,7 +41,7 @@ sub hook_mail {
 sub hook_rcpt {
 	my ($self, $transaction, $recipient, %args) = @_;
 
-	if (my $host = $self->qp->connection->notes('temp_resolver_failed')) {
+	if (my $host = $transaction->notes('temp_resolver_failed')) {
 		# default of temp_resolver_failed is DENYSOFT
 		return Qpsmtpd::DSN->temp_resolver_failed("Could not resolve " . $host);
 	}
@@ -148,4 +148,4 @@ sub mx_valid {
   return 0;
 }
 
-# vim: ts=2 sw=2 expandtab syn=perl
\ No newline at end of file
+# vim: ts=2 sw=2 expandtab syn=perl
-- 
1.7.2.3


-- 
   _  | Peter J. Holzer    | Web 2.0 könnte man also auch übersetzen als
|_|_) | Sysadmin WSR       | "Netz der kleinen Geister".
| |   | [email protected]         | 
__/   | http://www.hjp.at/ |  -- Oliver Cromm in desd
signature.asc (application/pgp-signature, 189 B)
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (GNU/Linux)

iD8DBQFNIazxfZ+RkG8quy0RAi+kAJ4hUkZrducBsIbQF5q2dVSNk34xOQCgxhzf
2vWEiL1Hmu90LFJUDNTmrNU=
=AfmO
-----END PGP SIGNATURE-----
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.