mime: acknowledge CURL_DISABLE_MIME

This commit is contained in:
Daniel Stenberg 2019-05-05 17:08:21 +02:00
parent 0e2208ada6
commit b95456f4e2
No known key found for this signature in database
GPG key ID: 5CC908FDB71E12C2
5 changed files with 42 additions and 79 deletions

View file

@ -2174,6 +2174,7 @@ CURLcode Curl_http(struct connectdata *conn, bool *done)
http->sendit = NULL;
}
#ifndef CURL_DISABLE_MIME
if(http->sendit) {
const char *cthdr = Curl_checkheaders(conn, "Content-Type");
@ -2198,6 +2199,7 @@ CURLcode Curl_http(struct connectdata *conn, bool *done)
return result;
http->postsize = Curl_mime_size(http->sendit);
}
#endif
ptr = Curl_checkheaders(conn, "Transfer-Encoding");
if(ptr) {
@ -2766,6 +2768,7 @@ CURLcode Curl_http(struct connectdata *conn, bool *done)
return result;
}
#ifndef CURL_DISABLE_MIME
/* Output mime-generated headers. */
{
struct curl_slist *hdr;
@ -2776,6 +2779,7 @@ CURLcode Curl_http(struct connectdata *conn, bool *done)
return result;
}
}
#endif
/* For really small posts we don't use Expect: headers at all, and for
the somewhat bigger ones we allow the app to disable it. Just make