Merge pull request #1777 from sbraz/proxyurl

Remove useless proxyurl handling from cURL HTTP backend
This commit is contained in:
qgarnier 2019-12-20 16:36:28 +01:00 committed by GitHub
commit 99c6d8de8a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 0 additions and 6 deletions

View File

@ -212,12 +212,6 @@ sub set_proxy {
my ($self, %options) = @_;
if (defined($options{request}->{proxyurl}) && $options{request}->{proxyurl} ne '') {
if ($options{request}->{proxyurl} =~ /^(?:http|https):\/\/(.*?):(.*?)@/) {
$self->curl_setopt(option => $self->{constant_cb}->(name => 'CURLOPT_PROXYUSERNAME'), parameter => $1);
$self->curl_setopt(option => $self->{constant_cb}->(name => 'CURLOPT_PROXYPASSWORD'), parameter => $2);
$options{request}->{proxyurl} =~ s/\/\/$1:$2@//;
}
$self->curl_setopt(option => $self->{constant_cb}->(name => 'CURLOPT_PROXY'), parameter => $options{request}->{proxyurl});
}