mirror of
https://github.com/moparisthebest/curl
synced 2024-12-22 08:08:50 -05:00
Mohun Biswas found out that formposting a zero-byte file didn't work very
good. I fixed.
This commit is contained in:
parent
72aff74798
commit
beb61ef429
4
CHANGES
4
CHANGES
@ -6,6 +6,10 @@
|
|||||||
|
|
||||||
Changelog
|
Changelog
|
||||||
|
|
||||||
|
Daniel (25 October 2004)
|
||||||
|
- Mohun Biswas found out that formposting a zero-byte file didn't work very
|
||||||
|
good. I fixed.
|
||||||
|
|
||||||
Daniel (19 October 2004)
|
Daniel (19 October 2004)
|
||||||
- Alexander Krasnostavsky made it possible to make FTP 3rd party transfers
|
- Alexander Krasnostavsky made it possible to make FTP 3rd party transfers
|
||||||
with both source and destination being the same host. It can be useful if
|
with both source and destination being the same host. It can be useful if
|
||||||
|
@ -1307,9 +1307,13 @@ size_t Curl_FormReader(char *buffer,
|
|||||||
if(!form->data)
|
if(!form->data)
|
||||||
return 0; /* nothing, error, empty */
|
return 0; /* nothing, error, empty */
|
||||||
|
|
||||||
if(form->data->type == FORM_FILE)
|
if(form->data->type == FORM_FILE) {
|
||||||
return readfromfile(form, buffer, wantedsize);
|
gotsize = readfromfile(form, buffer, wantedsize);
|
||||||
|
|
||||||
|
if(gotsize)
|
||||||
|
/* If positive or -1, return. If zero, continue! */
|
||||||
|
return gotsize;
|
||||||
|
}
|
||||||
do {
|
do {
|
||||||
|
|
||||||
if( (form->data->length - form->sent ) > wantedsize - gotsize) {
|
if( (form->data->length - form->sent ) > wantedsize - gotsize) {
|
||||||
|
Loading…
Reference in New Issue
Block a user