ID:               40169
 User updated by:  webmaster at bison-soft dot de
 Reported By:      webmaster at bison-soft dot de
-Status:           Closed
+Status:           Open
 Bug Type:         cURL related
 Operating System: irrelevant
 PHP Version:      5.2.1RC3
 New Comment:

Hello Tony,

IMHO, you have commentet out too much with your patch:

                case CURLOPT_AUTOREFERER:
                case CURLOPT_COOKIESESSION:
+#if LIBCURL_VERSION_NUM > 0x070b01 /* CURLOPT_TCP_NODELAY is available
since curl 7.11.2 */
                case CURLOPT_TCP_NODELAY:
                        convert_to_long_ex(zvalue);
                        error = curl_easy_setopt(ch->cp, option, 
Z_LVAL_PP(zvalue));
                        break;
+#endif
                case CURLOPT_FOLLOWLOCATION:

Shouldn't the #if only cover CURLOPT_TCP_NODELAY so that
curl_easy_setopt for the other two cases (CURLOPT_AUTOREFERER and
CURLOPT_COOKIESESSION) is done? It would then look like

                case CURLOPT_AUTOREFERER:
                case CURLOPT_COOKIESESSION:
+#if LIBCURL_VERSION_NUM > 0x070b01 /* CURLOPT_TCP_NODELAY is available
since curl 7.11.2 */
                case CURLOPT_TCP_NODELAY:
+#endif
                        convert_to_long_ex(zvalue);
                        error = curl_easy_setopt(ch->cp, option, 
Z_LVAL_PP(zvalue));
                        break;


Previous Comments:
------------------------------------------------------------------------

[2007-01-19 15:38:53] [EMAIL PROTECTED]

This bug has been fixed in CVS.

Snapshots of the sources are packaged every three hours; this change
will be in the next snapshot. You can grab the snapshot at
http://snaps.php.net/.
 
Thank you for the report, and for helping us make PHP better.



------------------------------------------------------------------------

[2007-01-19 15:22:50] webmaster at bison-soft dot de

Description:
------------
compile of curl extension in php 5.1.3rc3 fails when using libcurl <
7.11.2 because CURLOPT_TCP_NODELAY was first available in 7.11.2



Expected result:
----------------
Compiles cleanly even with curl version 7.10.6

Actual result:
--------------
usr/src/redhat/BUILD/php-5.2.1RC3/ext/curl/interface.c: In function
`zm_startup_curl':
/usr/src/redhat/BUILD/php-5.2.1RC3/ext/curl/interface.c:455:
`CURLOPT_TCP_NODELAY' undeclared (first use in this function)
/usr/src/redhat/BUILD/php-5.2.1RC3/ext/curl/interface.c:455: (Each
undeclared identifier is reported only once
/usr/src/redhat/BUILD/php-5.2.1RC3/ext/curl/interface.c:455: for each
function it appears in.)
/usr/src/redhat/BUILD/php-5.2.1RC3/ext/curl/interface.c: In function
`_php_curl_setopt':
/usr/src/redhat/BUILD/php-5.2.1RC3/ext/curl/interface.c:1267:
`CURLOPT_TCP_NODELAY' undeclared (first use in this function)



------------------------------------------------------------------------


-- 
Edit this bug report at http://bugs.php.net/?id=40169&edit=1

Reply via email to