body_write patches from Brian Grossman
git-svn-id: https://svn.perl.org/qpsmtpd/trunk@394 958fd67b-6ff1-0310-b445-bb7760255be9
This commit is contained in:
parent
321622f0aa
commit
6ecc991a20
@ -472,7 +472,7 @@ sub data {
|
|||||||
# save us buffering the mail content.
|
# save us buffering the mail content.
|
||||||
|
|
||||||
# Save the start of just the body itself
|
# Save the start of just the body itself
|
||||||
$self->transaction->body_start($size);
|
$self->transaction->set_body_start();
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -107,10 +107,12 @@ sub body_write {
|
|||||||
while ($$ref =~ m/\G(.*?\n)/gc) {
|
while ($$ref =~ m/\G(.*?\n)/gc) {
|
||||||
push @{ $self->{_body_array} }, $1;
|
push @{ $self->{_body_array} }, $1;
|
||||||
$self->{_body_size} += length($1);
|
$self->{_body_size} += length($1);
|
||||||
|
++$self->{_body_current_pos};
|
||||||
}
|
}
|
||||||
if ($$ref =~ m/\G(.+)\z/gc) {
|
if ($$ref =~ m/\G(.+)\z/gc) {
|
||||||
push @{ $self->{_body_array} }, $1;
|
push @{ $self->{_body_array} }, $1;
|
||||||
$self->{_body_size} += length($1);
|
$self->{_body_size} += length($1);
|
||||||
|
++$self->{_body_current_pos};
|
||||||
}
|
}
|
||||||
if ($self->{_body_size} >= $self->{_size_threshold}) {
|
if ($self->{_body_size} >= $self->{_size_threshold}) {
|
||||||
#warn("spooling to disk\n");
|
#warn("spooling to disk\n");
|
||||||
|
Loading…
Reference in New Issue
Block a user