From 7e9fd69bd88b143adba61c5c772abf9f9a912768 Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Mon, 16 Mar 2009 15:09:51 +0000 Subject: [PATCH] - MFH: Fixed bug #47616 (curl keeps crashing) --- NEWS | 1 + ext/curl/interface.c | 1 + 2 files changed, 2 insertions(+) diff --git a/NEWS b/NEWS index 723a26df16..7eddaab34d 100644 --- a/NEWS +++ b/NEWS @@ -9,6 +9,7 @@ PHP NEWS - Fixed bug #47667 (ZipArchive::OVERWRITE seems to have no effect). (Mikko,Pierre) - Fixed bug #47639 (pg_copy_from() WARNING: nonstandard use of \\ in a string literal). (Ilia) +- Fixed bug #47616 (curl keeps crashing). (Felipe) - Fixed bug #47598 (FILTER_VALIDATE_EMAIL is locale aware). (Ilia) - Fixed bug #47546 (Default value for limit parameter in explode is 0, not -1). (Kalle) diff --git a/ext/curl/interface.c b/ext/curl/interface.c index 0834c3b9a6..50bb162853 100644 --- a/ext/curl/interface.c +++ b/ext/curl/interface.c @@ -1572,6 +1572,7 @@ static int _php_curl_setopt(php_curl *ch, long option, zval **zvalue, zval *retu } else { #if LIBCURL_VERSION_NUM >= 0x071101 /* with curl 7.17.0 and later, we can use COPYPOSTFIELDS, but we have to provide size before */ + convert_to_string_ex(zvalue); error = curl_easy_setopt(ch->cp, CURLOPT_POSTFIELDSIZE, Z_STRLEN_PP(zvalue)); error = curl_easy_setopt(ch->cp, CURLOPT_COPYPOSTFIELDS, Z_STRVAL_PP(zvalue)); #else -- 2.40.0