Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Diff: source/http_request_builder.h
- Revision:
- 32:fa4d71265625
- Parent:
- 29:383e9bfbfbed
- Parent:
- 31:b3730a2c4f39
diff -r 3ad153a3fdfd -r fa4d71265625 source/http_request_builder.h
--- a/source/http_request_builder.h Thu Sep 06 14:01:09 2018 -0500
+++ b/source/http_request_builder.h Tue Oct 30 11:02:12 2018 +0800
@@ -58,14 +58,14 @@
}
}
- char* build(const void* body, unsigned int body_size, uint32_t &size, bool skip_content_length = false) {
+ char* build(const void* body, uint32_t body_size, uint32_t &size, bool skip_content_length = false) {
const char* method_str = http_method_str(method);
bool is_chunked = has_header("Transfer-Encoding", "chunked");
if (!is_chunked && (method == HTTP_POST || method == HTTP_PUT || method == HTTP_DELETE || body_size > 0)) {
char buffer[10];
- snprintf(buffer, 10, "%d", body_size);
+ snprintf(buffer, 10, "%lu", body_size);
set_header("Content-Length", string(buffer));
}