diff options
author | Daniel Stenberg <daniel@haxx.se> | 2018-08-18 16:17:05 +0200 |
---|---|---|
committer | Daniel Stenberg <daniel@haxx.se> | 2018-09-06 10:53:39 +0200 |
commit | 2825f46d950ca9b0e269ed8dc6a97c5238a17c30 (patch) | |
tree | 1869f93855474b2fe4469351b0dd5ef890bb1fb1 /lib/urldata.h | |
parent | 87fefe5ebfa152386396b8e232c7b5b0609f6f35 (diff) | |
download | curl-2825f46d950ca9b0e269ed8dc6a97c5238a17c30.tar.gz |
CURLOPT_UPLOAD_BUFFERSIZE: set upload buffer size
This is step 3 of #2888.
Fixes #2888
Closes #2896
Diffstat (limited to 'lib/urldata.h')
-rw-r--r-- | lib/urldata.h | 12 |
1 files changed, 2 insertions, 10 deletions
diff --git a/lib/urldata.h b/lib/urldata.h index 769ab4fa4..d3a174d24 100644 --- a/lib/urldata.h +++ b/lib/urldata.h @@ -142,14 +142,6 @@ typedef ssize_t (Curl_recv)(struct connectdata *conn, /* connection data */ #include <libssh2_sftp.h> #endif /* HAVE_LIBSSH2_H */ -/* The upload buffer size, should not be smaller than CURL_MAX_WRITE_SIZE, as - it needs to hold a full buffer as could be sent in a write callback. - - The size was 16KB for many years but was bumped to 64KB because it makes - libcurl able to do significantly faster uploads in some circumstances. Even - larger buffers can help further, but this is deemed a fair memory/speed - compromise. */ -#define UPLOAD_BUFSIZE 65536 /* The "master buffer" is for HTTP pipelining */ #define MASTERBUF_SIZE 16384 @@ -1585,8 +1577,8 @@ struct UserDefined { curl_proxytype proxytype; /* what kind of proxy that is in use */ long dns_cache_timeout; /* DNS cache timeout */ long buffer_size; /* size of receive buffer to use */ - long upload_buffer_size; /* size of upload buffer to use, - keep it >= CURL_MAX_WRITE_SIZE */ + size_t upload_buffer_size; /* size of upload buffer to use, + keep it >= CURL_MAX_WRITE_SIZE */ void *private_data; /* application-private data */ struct curl_slist *http200aliases; /* linked list of aliases for http200 */ |