1
0
mirror of https://github.com/moparisthebest/curl synced 2024-08-13 17:03:50 -04:00
Commit Graph

15 Commits

Author SHA1 Message Date
Daniel Stenberg
2e48139fbf lib554.c: use curl_formadd() properly
The length/size options take longs so make sure to pass on such types.

Reported by: Neil Bowers
Bug: http://curl.haxx.se/mail/lib-2012-06/0001.html
2012-06-07 23:10:40 +02:00
Dan Fandrich
cf0f6729e7 Silenced a compiler warning about an unused variable 2011-10-19 21:18:52 -07:00
Daniel Stenberg
840eff44f2 formdata: ack read callback abort
When doing a multipart formpost with a read callback, and that callback
returns CURL_READFUNC_ABORT, that return code must be properly
propagated back and handled accordingly. Previously it would be handled
as a zero byte read which would cause a hang!

Added test case 587 to verify. It uses the lib554.c source code with a
small ifdef.

Reported by: Anton Bychkov
Bug: http://curl.haxx.se/mail/lib-2011-10/0097.html
2011-10-16 01:09:56 +02:00
Daniel Stenberg
45d883d88d CURLFORM_BUFFER: insert filename as documented
A regression where CURLFORM_BUFFER stopped to properly insert the file
name part in the formpart. Bug introduced in commit f851f76857.

Added CURLFORM_BUFFER use to test 554 to verify this.

Bug: http://curl.haxx.se/mail/lib-2011-07/0176.html
Reported by: Henry Ludemann
2011-08-08 18:45:03 +02:00
Daniel Stenberg
f851f76857 CURLFORM_STREAM: acknowledge CURLFORM_FILENAME
The CURLFORM_STREAM is documented to only insert a file name (and thus
look like a file upload) in the part if CURLFORM_FILENAME is set, but in
reality it always inserted a filename="" and if CURLFORM_FILENAME wasn't
set, it would insert insert rubbish (or possibly crash).

This is now fixed to work as documented, and test 554 has been extended
to verify this.

Reported by: Sascha Swiercy
Bug: http://curl.haxx.se/mail/lib-2011-06/0070.html
2011-06-17 22:23:42 +02:00
Daniel Stenberg
1aeb635cdd sources: update source headers
All C and H files now (should) feature the proper project curl source
code header, which includes basic info, a copyright statement and some
basic disclaimers.
2011-03-10 12:04:33 +01:00
Daniel Stenberg
2309b4e330 remove the CVSish $Id$ lines 2010-03-24 11:02:54 +01:00
Yang Tse
cad9c3f55f Addes OOM handling for curl_easy_setopt() calls in test 2010-02-05 18:07:19 +00:00
Daniel Stenberg
9cff716925 don't set READDATA since it isn't used and only confuses readers 2009-07-22 22:08:01 +00:00
Yang Tse
c5c03ac556 Fixes for non-ASCII platforms by David McCreedy 2009-05-08 02:14:50 +00:00
Yang Tse
7beb473a3d include "memdebug.h" 2008-09-20 04:26:55 +00:00
Dan Fandrich
60f0b4fffe Fixed test 554 to pass the torture test. 2008-07-08 21:16:18 +00:00
Dan Fandrich
d31da176eb Made sure to pass longs in to curl_easy_setopt where necessary in the
libtest code.
2008-05-22 21:49:52 +00:00
Yang Tse
6fd3ff4032 fix compiler warning: argument is incompatible with corresponding format string conversion 2008-04-07 15:40:49 +00:00
Daniel Stenberg
a2314225e0 - Added CURLFORM_STREAM as a supported option to curl_formadd() to allow an
application to provide data for a multipart with the read callback. Note
  that the size needs to be provided with CURLFORM_CONTENTSLENGTH when the
  stream option is used. This feature is verified by the new test case
  554. This feature was sponsored by Xponaut.
2008-03-31 10:02:23 +00:00