mirror of
https://github.com/curl/curl.git
synced 2026-08-05 21:46:18 +03:00
Enabled a few more gcc warnings with --enable-debug. Renamed a few
variables to avoid shadowing global declarations.
This commit is contained in:
parent
9c5cd6c413
commit
16b95fc773
16 changed files with 102 additions and 98 deletions
|
|
@ -950,21 +950,21 @@ int curl_formget(struct curl_httppost *form, void *arg,
|
|||
for (ptr = data; ptr; ptr = ptr->next) {
|
||||
if (ptr->type == FORM_FILE) {
|
||||
char buffer[8192];
|
||||
size_t read;
|
||||
size_t nread;
|
||||
struct Form temp;
|
||||
|
||||
Curl_FormInit(&temp, ptr);
|
||||
|
||||
do {
|
||||
read = readfromfile(&temp, buffer, sizeof(buffer));
|
||||
if ((read == (size_t) -1) || (read != append(arg, buffer, read))) {
|
||||
nread = readfromfile(&temp, buffer, sizeof(buffer));
|
||||
if ((nread == (size_t) -1) || (nread != append(arg, buffer, nread))) {
|
||||
if (temp.fp) {
|
||||
fclose(temp.fp);
|
||||
}
|
||||
Curl_formclean(&data);
|
||||
return -1;
|
||||
}
|
||||
} while (read == sizeof(buffer));
|
||||
} while (nread == sizeof(buffer));
|
||||
} else {
|
||||
if (ptr->length != append(arg, ptr->line, ptr->length)) {
|
||||
Curl_formclean(&data);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue