Commit Graph

550 Commits

Author SHA1 Message Date
Anatol Belski
cc34dfce16 Merge branch 'PHP-5.3' into PHP-5.4
* PHP-5.3:
  fix the test for curl 7.29.0+
2013-02-19 09:04:52 +01:00
Anatol Belski
558c5dbe65 fix the test for curl 7.29.0+ 2013-02-19 09:04:06 +01:00
Xinchen Hui
0a7395e009 Happy New Year 2013-01-01 16:28:54 +08:00
Xinchen Hui
a2045ff332 Happy New Year~ 2013-01-01 16:02:16 +08:00
Pierrick Charron
ac3d227e28 Fixed #63859 Memory leak when reusing curl-handle
When CURLOPT_POSTFIELDS is called more than once on the same
curl handle, php/curl did not free the memory of the previous
post data. This commit will fix the problem unless the curl
handle was previously duplicated using the curl_copy_handle()
function in which case we can not know if the post data is
still in use or not by any curl handle
2012-12-27 13:31:55 -05:00
Pierrick Charron
b10a3b9466 Merge branch 'PHP-5.3' into PHP-5.4
* PHP-5.3:
  Fixed segfault due to libcurl connection caching
2012-12-22 19:04:45 -05:00
Pierrick Charron
a2b6d9c104 Fixed segfault due to libcurl connection caching
Libcurl is doing connection caching. When easy handle is cleaned up,
if the handle was previously used by the curl_multi_api, the connection
remains open un the curl multi handle is cleaned up. Some protocols are
sending content like the FTP one, and libcurl try to use the
WRITEFUNCTION or the HEADERFUNCTION. Since structures used in those
callback are freed, we need to use an other callback to which avoid
segfaults.

Libcurl commit d021f2e8a00 fix this issue and should be part of 7.28.2
2012-12-22 19:03:24 -05:00
Pierrick Charron
5499c7d201 Merge branch 'PHP-5.3' into PHP-5.4
* PHP-5.3:
  Update NEWS file
  Fixed bug #63352 (Can't enable hostname validation when using curl stream wrappers)
  CURL >= 7.28.0 no longer support value 1 for CURLOPT_SSL_VERIFYHOST)

Conflicts:
	ext/curl/interface.c
	ext/curl/tests/bug63363.phpt
2012-12-21 19:24:28 -05:00
Pierrick Charron
af10e698a2 Fixed bug #63352 (Can't enable hostname validation when using curl stream wrappers) 2012-12-21 19:12:43 -05:00
Pierrick Charron
517f800277 CURL >= 7.28.0 no longer support value 1 for CURLOPT_SSL_VERIFYHOST)
Fixed bug #63795
2012-12-21 19:10:55 -05:00
Pierrick Charron
763bce0303 Fix test
This test is only valid if libcurl < 7.28.1 since
libcurl removed support for the 1 value in CURLOPT_SSL_VERIFYHOST.
2012-12-21 11:45:59 -05:00
Pierrick Charron
66b88c92bb Merge branch 'PHP-5.3' into PHP-5.4
* PHP-5.3:
  Fixed bug #55438 (Curlwapper is not sending http header randomly)
2012-12-19 19:44:08 -05:00
Pierrick Charron
c46e1cdcae Fixed bug #55438 (Curlwapper is not sending http header randomly)
Since curl multi is used, it sometime happen that the resource is freed before
the curl multi really execute the query. The patch will store the headers
slist in the curlstream handle and free it only when the stream will be closed
2012-12-19 19:40:29 -05:00
Xinchen Hui
e54970aaf1 Unused variable copystr
copystr is declared again blow
2012-11-21 12:30:03 +08:00
John Jawed (JJ)
f68f31f121 Notice if CURLOPT_SSL_VERIFYHOST is set to true 2012-10-25 16:00:02 -04:00
Xinchen Hui
610c7fbe7b Remove executable permission on phpt 2012-10-10 10:27:49 +08:00
Xinchen Hui
e081c55fb5 Merge branch 'PHP-5.3' into PHP-5.4 2012-10-10 10:31:31 +08:00
Pierrick Charron
a2a8220127 Merge branch 'PHP-5.3' into PHP-5.4
* PHP-5.3:
  FD_ZERO file descriptors before calling curl_multi_fdset
2012-09-28 15:21:33 -04:00
Pierrick Charron
936553d666 FD_ZERO file descriptors before calling curl_multi_fdset
As per curl documentation http://curl.haxx.se/libcurl/c/curl_multi_fdset.html
we need to FD_ZERO file descriptors before calling the curl_multi_fdset function
2012-09-28 15:21:03 -04:00
Pierrick Charron
c8687ee63b Merge branch 'PHP-5.3' into PHP-5.4
* PHP-5.3:
  Avoid calling select if maxfd returned by curl_multi_fdset is -1
2012-09-22 10:18:44 -04:00
Pierrick Charron
2e8ab65270 Avoid calling select if maxfd returned by curl_multi_fdset is -1
As per libcurl documentation :

When libcurl returns -1 in max_fd, it is because libcurl currently
does something that isn't possible for your application to monitor
with a socket and unfortunately you can then not know exactly when
the current action is completed using select().
2012-09-22 10:15:40 -04:00
Xinchen Hui
e2d1eecf99 Merge branch 'PHP-5.3' into PHP-5.4 2012-09-18 10:48:16 +08:00
Xinchen Hui
e66a5ce56f Fixed Bug #63103 (ext\curl\tests\bug62839.phpt broken) 2012-09-18 10:46:58 +08:00
Pierrick Charron
4c83ecc754 Fixed bug #62912 (CURLINFO_PRIMARY_IP is not exposed)
CURLINFO_PRIMARY_* and CURLINFO_LOCAL_* where available in curl_getinfo
but the constant itself was not exposed to php userland
2012-08-24 10:16:40 -04:00
Pierrick Charron
8ac61a3e60 Merge branch 'PHP-5.3' into PHP-5.4
* PHP-5.3:
  Fixed bug #62839
2012-08-16 14:50:06 -04:00
Pierrick Charron
9cf0139460 Fixed bug #62839
curl_copy_handle segfault with CURLOPT_FILE. The refcount was incremented
before the assignement.
2012-08-16 14:48:44 -04:00
Xinchen Hui
0398cc22a9 Merge branch 'PHP-5.3' into PHP-5.4
* PHP-5.3:
  Fixed bug #62499 (curl_setopt($ch, CURLOPT_COOKIEFILE, "") returns false)
  appease MSVC (doesnt like unary minus of unsigned ints)

Conflicts:
	ext/curl/interface.c
2012-07-09 08:38:03 +08:00
Xinchen Hui
c819cf9d6b Fixed bug #62499 (curl_setopt($ch, CURLOPT_COOKIEFILE, "") returns false)
this bc break is caused by the fix for #61948
2012-07-09 08:32:40 +08:00
Anatoliy Belsky
16a592b13a Merge branch 'PHP-5.3' into PHP-5.4
* PHP-5.3:
  Fixed bug #62149 Test Bug - ext/curl/tests/bug61948
  Fixed bug #62148 mail_skipif doesn't skip imap tests on Release Build
2012-05-25 10:52:38 +02:00
Matt Ficken
86d2fafded Fixed bug #62149 Test Bug - ext/curl/tests/bug61948 2012-05-25 10:44:59 +02:00
Xinchen Hui
0747b29bdf Merge branch 'PHP-5.3' into PHP-5.4
* PHP-5.3:
  correct NEWS
  Fixed bug #61948 (CURLOPT_COOKIEFILE '' raises open_basedir restriction)

Conflicts:
	ext/curl/interface.c
2012-05-06 00:52:51 +08:00
Xinchen Hui
19632ae7dc Fixed bug #61948 (CURLOPT_COOKIEFILE '' raises open_basedir restriction) 2012-05-06 00:50:37 +08:00
Xinchen Hui
035ce937e1 Fixed bug #61948 (CURLOPT_COOKIEFILE '' raises open_basedir restriction) 2012-05-06 00:40:49 +08:00
Christopher Jones
dbefe8d8ea Allow alternative curl output shown in several qa.php.net/reports logs 2012-02-06 23:14:47 +00:00
Christopher Jones
a46497fd19 Allow alternative curl output shown in several qa.php.net/reports logs 2012-02-06 23:14:47 +00:00
Felipe Pena
e4ca0ed09f - Year++ 2012-01-01 13:15:04 +00:00
Felipe Pena
4e19825281 - Year++ 2012-01-01 13:15:04 +00:00
Pierrick Charron
e8eab79ac8 Fix curl_copy_handle_basic_008.phpt when display_errors is On
(Thanks Chris Jones)
2011-12-08 18:57:01 +00:00
Pierrick Charron
4b860ccdad Fix curl_copy_handle_basic_008.phpt when display_errors is On
(Thanks Chris Jones)
2011-12-08 18:57:01 +00:00
Pierrick Charron
bc8fc80049 Fix test 2011-12-07 16:46:48 +00:00
Pierrick Charron
2e87cd3399 Fix test 2011-12-07 16:46:48 +00:00
Pierrick Charron
4093e5e797 Add new test for CURLOPT_POSTFIELDS 2011-12-07 16:32:50 +00:00
Pierrick Charron
572e36e2e4 Add new test for CURLOPT_POSTFIELDS 2011-12-07 16:32:50 +00:00
Pierrick Charron
109346779a Fixed bug #60439curl_copy_handle segfault when used with CURLOPT_PROGRESSFUNCTION 2011-12-04 01:34:54 +00:00
Pierrick Charron
191835fd3d Fixed bug #60439curl_copy_handle segfault when used with CURLOPT_PROGRESSFUNCTION 2011-12-04 01:34:54 +00:00
Pierrick Charron
3fe47ef089 Cleans up test file 2011-12-02 04:16:46 +00:00
Pierrick Charron
a2d189883f Cleans up test file 2011-12-02 04:16:46 +00:00
Pierrick Charron
def84f16ad Fix test to remove dependancy over php.net 2011-11-22 18:50:57 +00:00
Pierrick Charron
b0b58c3d08 Fix test to remove dependancy over php.net 2011-11-22 18:50:57 +00:00
Pierrick Charron
0f26db6956 Fix this test to work with all version (even old) of libcurl 2011-11-22 08:29:26 +00:00