[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[libmicrohttpd] 03/06: Upgraded TLS: fixed inefficient communication
From: |
gnunet |
Subject: |
[libmicrohttpd] 03/06: Upgraded TLS: fixed inefficient communication |
Date: |
Fri, 31 Mar 2023 09:22:49 +0200 |
This is an automated email from the git hooks/post-receive script.
karlson2k pushed a commit to branch master
in repository libmicrohttpd.
commit 6b5e509ff088d05c1033c6773169d8d001991b95
Author: Evgeny Grin (Karlson2k) <k2k@narod.ru>
AuthorDate: Thu Mar 30 18:09:36 2023 +0200
Upgraded TLS: fixed inefficient communication
---
src/microhttpd/response.c | 15 ++++++++++++++-
1 file changed, 14 insertions(+), 1 deletion(-)
diff --git a/src/microhttpd/response.c b/src/microhttpd/response.c
index f0ca7825..fc006da2 100644
--- a/src/microhttpd/response.c
+++ b/src/microhttpd/response.c
@@ -2045,13 +2045,26 @@ MHD_response_execute_upgrade_ (struct MHD_Response
*response,
free (urh);
return MHD_NO;
}
+ pool = connection->pool;
+ if (0 != connection->write_buffer_size)
+ {
+ mhd_assert (NULL != connection->write_buffer);
+ /* All data should be sent already */
+ mhd_assert (connection->write_buffer_send_offset == \
+ connection->write_buffer_append_offset);
+ (void) MHD_pool_reallocate (pool, connection->write_buffer,
+ connection->write_buffer_size, 0);
+ connection->write_buffer_append_offset = 0;
+ connection->write_buffer_send_offset = 0;
+ connection->write_buffer_size = 0;
+ }
+ connection->write_buffer = NULL;
urh->app.socket = sv[0];
urh->app.urh = urh;
urh->app.celi = MHD_EPOLL_STATE_UNREADY;
urh->mhd.socket = sv[1];
urh->mhd.urh = urh;
urh->mhd.celi = MHD_EPOLL_STATE_UNREADY;
- pool = connection->pool;
avail = MHD_pool_get_free (pool);
if (avail < RESERVE_EBUF_SIZE)
{
--
To stop receiving notification emails like this one, please contact
gnunet@gnunet.org.
- [libmicrohttpd] branch master updated (ec981dfe -> da42f22c), gnunet, 2023/03/31
- [libmicrohttpd] 03/06: Upgraded TLS: fixed inefficient communication,
gnunet <=
- [libmicrohttpd] 02/06: microhttpd.h: fixed typo in doxy, gnunet, 2023/03/31
- [libmicrohttpd] 01/06: ChangeLog: corrected, gnunet, 2023/03/31
- [libmicrohttpd] 04/06: connection.c: cosmetics, gnunet, 2023/03/31
- [libmicrohttpd] 05/06: Upgraded connection: replaced two checks with asserts, gnunet, 2023/03/31
- [libmicrohttpd] 06/06: Upgraded TLS: use more available memory for pumping the data, gnunet, 2023/03/31