Round timeouts less then 1 but greater than 0 to 1 for curl transport. see #8086
git-svn-id: https://develop.svn.wordpress.org/trunk@10025 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
0d75a8896b
commit
62ddc13d82
@ -973,6 +973,10 @@ class WP_Http_Curl {
|
|||||||
unset($r['headers']['user-agent']);
|
unset($r['headers']['user-agent']);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// If timeout is a float less than 1, round it up to 1.
|
||||||
|
if ( $r['timeout'] > 0 && $r['timeout'] < 1 )
|
||||||
|
$r['timeout'] = 1;
|
||||||
|
|
||||||
$handle = curl_init();
|
$handle = curl_init();
|
||||||
curl_setopt( $handle, CURLOPT_URL, $url);
|
curl_setopt( $handle, CURLOPT_URL, $url);
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user