[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[libmicrohttpd] 01/08: upgrade response: set response size to zero
From: |
gnunet |
Subject: |
[libmicrohttpd] 01/08: upgrade response: set response size to zero |
Date: |
Sun, 13 Mar 2022 18:33:24 +0100 |
This is an automated email from the git hooks/post-receive script.
karlson2k pushed a commit to branch master
in repository libmicrohttpd.
commit b26d68a71c1e001383d35bdfbc958d7caa2aedde
Author: Evgeny Grin (Karlson2k) <k2k@narod.ru>
AuthorDate: Tue Mar 8 10:35:47 2022 +0300
upgrade response: set response size to zero
Upgrade responses do not have body, so zero must be used as the body size.
---
src/microhttpd/connection.c | 2 --
src/microhttpd/response.c | 2 +-
2 files changed, 1 insertion(+), 3 deletions(-)
diff --git a/src/microhttpd/connection.c b/src/microhttpd/connection.c
index def03b68..3a1c3c43 100644
--- a/src/microhttpd/connection.c
+++ b/src/microhttpd/connection.c
@@ -3968,8 +3968,6 @@ MHD_connection_handle_write (struct MHD_Connection
*connection)
(NULL != resp->crc) );
mhd_assert ( (0 == connection->response_write_position) || \
(resp->total_size ==
- connection->response_write_position) || \
- (MHD_SIZE_UNKNOWN ==
connection->response_write_position) );
mhd_assert ((MHD_CONN_MUST_UPGRADE != connection->keepalive) || \
(! connection->rp_props.send_reply_body));
diff --git a/src/microhttpd/response.c b/src/microhttpd/response.c
index 3fd98088..e12b44a8 100644
--- a/src/microhttpd/response.c
+++ b/src/microhttpd/response.c
@@ -1942,7 +1942,7 @@ MHD_create_response_for_upgrade (MHD_UpgradeHandler
upgrade_handler,
#endif
response->upgrade_handler = upgrade_handler;
response->upgrade_handler_cls = upgrade_handler_cls;
- response->total_size = MHD_SIZE_UNKNOWN;
+ response->total_size = 0;
response->reference_count = 1;
if (MHD_NO ==
MHD_add_response_header (response,
--
To stop receiving notification emails like this one, please contact
gnunet@gnunet.org.
- [libmicrohttpd] branch master updated (1a46bfd6 -> f2565a62), gnunet, 2022/03/13
- [libmicrohttpd] 04/08: Disallowed successful responses for CONNECT requests, gnunet, 2022/03/13
- [libmicrohttpd] 03/08: Added warning in log if application-defined Content-Length is used, gnunet, 2022/03/13
- [libmicrohttpd] 02/08: Added separate internal "responseIcy" flag., gnunet, 2022/03/13
- [libmicrohttpd] 01/08: upgrade response: set response size to zero,
gnunet <=
- [libmicrohttpd] 06/08: MHD_queue_response(): refuse 101 code when not supported, gnunet, 2022/03/13
- [libmicrohttpd] 05/08: MHD_queue_response(): clarified log message, gnunet, 2022/03/13
- [libmicrohttpd] 07/08: Simplified function for determining needs for reply body and headers, gnunet, 2022/03/13
- [libmicrohttpd] 08/08: MHD_set_response_options(): check whether the new flags could be used, gnunet, 2022/03/13