[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[GNUnet-SVN] [taler-twister] 01/02: Only set Content-Length via CURLOPT_
From: |
gnunet |
Subject: |
[GNUnet-SVN] [taler-twister] 01/02: Only set Content-Length via CURLOPT_POSTFIELDSIZE. |
Date: |
Thu, 16 May 2019 11:58:30 +0200 |
This is an automated email from the git hooks/post-receive script.
marcello pushed a commit to branch master
in repository twister.
commit 215029dc3f777a5666ad88afbd5c802691cb4c8c
Author: Marcello Stanisci <address@hidden>
AuthorDate: Thu May 16 11:56:50 2019 +0200
Only set Content-Length via CURLOPT_POSTFIELDSIZE.
---
src/twister/taler-twister-service.c | 15 ++++++---------
1 file changed, 6 insertions(+), 9 deletions(-)
diff --git a/src/twister/taler-twister-service.c
b/src/twister/taler-twister-service.c
index 82a009a..c77a2df 100644
--- a/src/twister/taler-twister-service.c
+++ b/src/twister/taler-twister-service.c
@@ -904,17 +904,13 @@ con_val_iter (void *cls,
return MHD_YES;
}
- if (GNUNET_YES == malform_upload)
+ if ((0 == strcmp (MHD_HTTP_HEADER_CONTENT_LENGTH,
+ key)))
{
- if (0 == strcmp ("Content-Length", key))
- {
- GNUNET_asprintf (&new_value,
- "%lu",
- malformed_size);
- value = new_value;
- malform_upload = GNUNET_NO;
- }
+ TALER_LOG_INFO ("Do not re-set Content-Length for request
(CURLOPT_POSTFIELDSIZE did)\n");
+ return MHD_YES;
}
+
GNUNET_asprintf (&hdr,
"%s: %s",
key,
@@ -1478,6 +1474,7 @@ create_response (void *cls,
malformed_size = GNUNET_CRYPTO_random_u32
(GNUNET_CRYPTO_QUALITY_WEAK, hr->io_len);
hr->io_len = malformed_size;
+ malform_upload = no;
}
if ('\0' != flip_path_ul[0])
--
To stop receiving notification emails like this one, please contact
address@hidden