]> granicus.if.org Git - php/commitdiff
Fixed bug #27341 (HEAD requests fail to return data).
authorIlia Alshanetsky <iliaa@php.net>
Mon, 23 Feb 2004 19:50:07 +0000 (19:50 +0000)
committerIlia Alshanetsky <iliaa@php.net>
Mon, 23 Feb 2004 19:50:07 +0000 (19:50 +0000)
ext/curl/interface.c

index 8dc4bea3e4d3f24f62bea6719d6cde80dbe131ec..f622c8bc77d90818546d0d0bfcd5e6b645de9cf3 100644 (file)
@@ -1132,7 +1132,8 @@ PHP_FUNCTION(curl_exec)
        
        error = curl_easy_perform(ch->cp);
        SAVE_CURL_ERROR(ch, error);
-       if (error != CURLE_OK) {
+       /* CURLE_PARTIAL_FILE is returned by HEAD requests */
+       if (error != CURLE_OK && error != CURLE_PARTIAL_FILE) {
                if (ch->handlers->write->buf.len > 0) {
                        smart_str_free(&ch->handlers->write->buf);
                }