mirror of
https://github.com/friendica/friendica
synced 2025-04-26 07:10:12 +00:00
Semaphore lock deactivated for PHP lower 5.6.1
This commit is contained in:
parent
65ffd1bc2b
commit
42a8f27034
2 changed files with 11 additions and 2 deletions
|
@ -150,6 +150,10 @@ function z_fetch_url($url, $binary = false, &$redirects = 0, $opts = array()) {
|
|||
}
|
||||
}
|
||||
|
||||
if (Config::get('system', 'ipv4_resolve', false)) {
|
||||
curl_setopt($ch, CURLOPT_IPRESOLVE, CURL_IPRESOLVE_V4);
|
||||
}
|
||||
|
||||
if ($binary) {
|
||||
@curl_setopt($ch, CURLOPT_BINARYTRANSFER, 1);
|
||||
}
|
||||
|
@ -278,6 +282,10 @@ function post_url($url, $params, $headers = null, &$redirects = 0, $timeout = 0)
|
|||
curl_setopt($ch, CURLOPT_POSTFIELDS, $params);
|
||||
curl_setopt($ch, CURLOPT_USERAGENT, $a->get_useragent());
|
||||
|
||||
if (Config::get('system', 'ipv4_resolve', false)) {
|
||||
curl_setopt($ch, CURLOPT_IPRESOLVE, CURL_IPRESOLVE_V4);
|
||||
}
|
||||
|
||||
if (intval($timeout)) {
|
||||
curl_setopt($ch, CURLOPT_TIMEOUT, $timeout);
|
||||
} else {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue