… | |
… | |
205 | } |
205 | } |
206 | } |
206 | } |
207 | |
207 | |
208 | if ($self->{method} ne "HEAD" |
208 | if ($self->{method} ne "HEAD" |
209 | && $self->{h}{"accept-encoding"} =~ /\bgzip\b/ |
209 | && $self->{h}{"accept-encoding"} =~ /\bgzip\b/ |
|
|
210 | && 400 < length $content |
210 | && $hdr->{"Content-Length"} == length $content |
211 | && $hdr->{"Content-Length"} == length $content |
211 | && !exists $hdr->{"Content-Encoding"} |
212 | && !exists $hdr->{"Content-Encoding"} |
212 | ) { |
213 | ) { |
213 | my $orig = length $content; |
214 | my $orig = length $content; |
214 | $hdr->{"Content-Encoding"} = "gzip"; |
215 | $hdr->{"Content-Encoding"} = "gzip"; |