develooper Front page | perl.qpsmtpd | Postings from September 2007

Re: more reset_connection() and uninitialized values

Thread Previous | Thread Next
From:
John Peacock
Date:
September 30, 2007 08:49
Subject:
Re: more reset_connection() and uninitialized values
Message ID:
46FFC57C.3050208@rowman.com
Hanno Hecker wrote:
> Index: lib/Qpsmtpd/SMTP.pm
> ===================================================================
> --- lib/Qpsmtpd/SMTP.pm	(revision 804)
> +++ lib/Qpsmtpd/SMTP.pm	(working copy)
> @@ -802,6 +802,7 @@
>    my ($self, $rc, $msg, $args) = @_;
>    
>    # reset transaction if we queued the mail
> +  $self->reset_connection;
>    $self->reset_transaction;
>    
>    if ($rc == DONE) {

Except if it is written properly, reset_connection should in fact drop the
transaction object as well, so the order you chose should be a noop.  I would do
that the other way round: connections contain transactions, so unroll them in
reverse.

John

Thread Previous | Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About