From 2825f46d950ca9b0e269ed8dc6a97c5238a17c30 Mon Sep 17 00:00:00 2001 From: Daniel Stenberg Date: Sat, 18 Aug 2018 16:17:05 +0200 Subject: CURLOPT_UPLOAD_BUFFERSIZE: set upload buffer size This is step 3 of #2888. Fixes #2888 Closes #2896 --- lib/smb.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'lib/smb.c') diff --git a/lib/smb.c b/lib/smb.c index e4b18fcf5..e1209e099 100644 --- a/lib/smb.c +++ b/lib/smb.c @@ -610,7 +610,8 @@ static CURLcode smb_send_and_recv(struct connectdata *conn, void **msg) /* Check if there is data in the transfer buffer */ if(!smbc->send_size && smbc->upload_size) { - size_t nread = smbc->upload_size > UPLOAD_BUFSIZE ? UPLOAD_BUFSIZE : + size_t nread = smbc->upload_size > conn->data->set.upload_buffer_size ? + conn->data->set.upload_buffer_size : smbc->upload_size; conn->data->req.upload_fromhere = conn->data->state.ulbuf; result = Curl_fillreadbuffer(conn, nread, &nread); -- cgit v1.2.3