From 665b3e48bc95713ecceaddf445fc2049440a6fb3 Mon Sep 17 00:00:00 2001 From: Patrick Monnerat Date: Thu, 12 Oct 2017 14:25:59 +0100 Subject: cli tool: reimplement stdin buffering in -F option. If stdin is not a regular file, its content is memory-buffered to enable a possible data "rewind". In all cases, stdin data size is determined before real use to avoid having an unknown part's size. --libcurl generated code is left as an unbuffered stdin fread/fseek callback part with unknown data size. Buffering is not supported in deprecated curl_formadd() API. --- tests/data/test173 | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) (limited to 'tests/data/test173') diff --git a/tests/data/test173 b/tests/data/test173 index 754950105..865ef7ba2 100644 --- a/tests/data/test173 +++ b/tests/data/test173 @@ -53,11 +53,9 @@ POST /we/want/173 HTTP/1.1 User-Agent: curl/7.12.1-CVS (i686-pc-linux-gnu) libcurl/7.12.1-CVS OpenSSL/0.9.6b ipv6 zlib/1.1.4 GSS libidn/0.4.6 Host: %HOSTIP:%HTTPPORT Accept: */* -Transfer-Encoding: chunked -Expect: 100-continue +Content-Length: 360 Content-Type: multipart/form-data; boundary=----------------------------5dbea401cd8c -168 ------------------------------5dbea401cd8c Content-Disposition: form-data; name="field1" @@ -76,9 +74,6 @@ line7 line8 ------------------------------5dbea401cd8c-- - -0 - -- cgit v1.2.3