... when looking for the status code with a CGI prefix
that starts with https://. We care about the status code
sent by the impersonated web server.
sub get_status_code($) {
my $buffer_ref = shift;
+ our $privoxy_cgi_url;
+
+ my $skip_connection_established_response = $privoxy_cgi_url =~ m@^https://@;
my @buffer = @{$buffer_ref};
foreach (@buffer) {
+ if ($skip_connection_established_response) {
+
+ next if (m@^HTTP/1\.1 200 Connection established@);
+ next if (m@^\r\n$@);
+ $skip_connection_established_response = 0;
+ }
+
if (/^HTTP\/\d\.\d (\d{3})/) {
return $1;