summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ext/curl/curl.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/ext/curl/curl.c b/ext/curl/curl.c
index 2c20a5c450..0ef082d394 100644
--- a/ext/curl/curl.c
+++ b/ext/curl/curl.c
@@ -825,7 +825,7 @@ PHP_FUNCTION(curl_exec)
error = curl_easy_perform(ch->cp);
if (error != CURLE_OK) {
- if (ch->handlers->write->buf)
+ if (ch->handlers->write->buf.c)
smart_str_free(&ch->handlers->write->buf);
SAVE_CURL_ERROR(ch, error);
RETURN_FALSE;