Skip to content

Commit

Permalink
Merge pull request #187 from lechbaczynski/master
Browse files Browse the repository at this point in the history
- adding option for forcing ipv4
  • Loading branch information
dcramer committed Jan 23, 2015
2 parents e5528ac + 90f8cf4 commit bc21d0a
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion lib/Raven/Client.php
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,7 @@ public function __construct($options_or_dsn=null, $options=array())
$this->send_callback = Raven_Util::get($options, 'send_callback', null);
$this->curl_method = Raven_Util::get($options, 'curl_method', 'sync');
$this->curl_path = Raven_Util::get($options, 'curl_path', 'curl');
$this->curl_ipv4 = Raven_util::get($options, 'curl_ipv4', true);
$this->ca_cert = Raven_util::get($options, 'ca_cert', $this->get_default_ca_cert());
$this->curl_ssl_version = Raven_Util::get($options, 'curl_ssl_version');

Expand Down Expand Up @@ -551,7 +552,10 @@ protected function get_curl_options()
}
if ($this->curl_ssl_version) {
$options[CURLOPT_SSLVERSION] = $this->curl_ssl_version;
}
}
if ($this->curl_ipv4) {
$options[CURLOPT_IPRESOLVE] = CURL_IPRESOLVE_V4;
}
if (defined('CURLOPT_TIMEOUT_MS')) {
// MS is available in curl >= 7.16.2
$timeout = max(1, ceil(1000 * $this->timeout));
Expand Down

0 comments on commit bc21d0a

Please sign in to comment.