cvs: php-src /ext/curl interface.c
| From: | Jani Taskinen | Date: | Mon, 26 Jan 2004 00:16:16 +0000 |
| Subject: | cvs: php-src /ext/curl interface.c | ||
| Groups: | php.cvs | ||
| Request: | Send a blank email to php-cvs+get-25862@lists.php.net to get a copy of this message | ||
sniper Sun Jan 25 19:16:16 2004 EDT
Modified files:
/php-src/ext/curl interface.c
Log:
- Fixed bug #27040 (passing an array of form-fields to CURLOPT_POSTFIELDS does not work).
http://cvs.php.net/diff.php/php-src/ext/curl/interface.c?r1=1.29&r2=1.30&ty=u
Index: php-src/ext/curl/interface.c
diff -u php-src/ext/curl/interface.c:1.29 php-src/ext/curl/interface.c:1.30
--- php-src/ext/curl/interface.c:1.29 Thu Jan 8 03:14:37 2004
+++ php-src/ext/curl/interface.c Sun Jan 25 19:16:16 2004
@@ -16,7 +16,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: interface.c,v 1.29 2004/01/08 08:14:37 andi Exp $ */
+/* $Id: interface.c,v 1.30 2004/01/26 00:16:16 sniper Exp $ */
#define ZEND_INCLUDE_FULL_WINDOWS_HEADERS
@@ -1001,7 +1001,7 @@
error = curl_formadd(&first, &last,
CURLFORM_COPYNAME, string_key,
CURLFORM_NAMELENGTH, string_key_len - 1,
- CURLFORM_PTRCONTENTS, postval,
+ (ZVAL_REFCOUNT(*zvalue) > 1 ? CURLFORM_PTRCONTENTS : CURLFORM_COPYCONTENTS),
postval,
CURLFORM_CONTENTSLENGTH, Z_STRLEN_PP(current),
CURLFORM_END);
}