]> Sergey Matveev's repositories - public-inbox.git/blobdiff - lib/PublicInbox/POP3.pm
pop3: TOP requests do not expire messages
[public-inbox.git] / lib / PublicInbox / POP3.pm
index 51c2b71a560fd10e041ad8bb949e2b8c3ab6486e..2c20c84b0e1022f6594227d8de9f1a4cb2aaf4fb 100644 (file)
@@ -300,12 +300,13 @@ sub retr_cb { # called by git->cat_async via ibx_async_cat
                $hdr .= "\r\n\r\n";
                my @tmp = split(/^/m, $bdy);
                $hdr .= join('', splice(@tmp, 0, $top_nr));
+       } elsif (exists $self->{expire}) {
+               $self->{expire} .= pack('S', $off + 1);
        }
        $$bref =~ s/^\./../gms;
        $$bref .= substr($$bref, -2, 2) eq "\r\n" ? ".\r\n" : "\r\n.\r\n";
        $self->msg_more("+OK message follows\r\n");
        $self->write($bref);
-       $self->{expire} .= pack('S', $off + 1) if exists $self->{expire};
        $self->requeue;
 }