tor

The Tor anonymity network
git clone https://git.dasho.dev/tor.git
Log | Files | Refs | README | LICENSE

commit f1932265fc2da57c6bda1813b57b74d24eff21fe
parent 5336ac26693cdba47422771ea951d22a290f67df
Author: Alexander Færøy <ahf@torproject.org>
Date:   Mon, 29 Jun 2020 14:09:53 +0000

Merge branch 'dgoulet/tor-ticket40008_045_01'

Diffstat:
Msrc/core/or/scheduler_kist.c | 5+++++
1 file changed, 5 insertions(+), 0 deletions(-)

diff --git a/src/core/or/scheduler_kist.c b/src/core/or/scheduler_kist.c @@ -445,6 +445,11 @@ update_socket_written(socket_table_t *table, channel_t *chan, size_t bytes) * one cell for each and bouncing back and forth. This KIST impl avoids that * by only writing a channel's outbuf to the kernel if it has 8 cells or more * in it. + * + * Note: The number 8 has been picked for no particular reasons except that it + * is 4096 bytes which is a common number for buffering. A TLS record can hold + * up to 16KiB thus using 8 cells means that a relay will at most send a TLS + * record of 4KiB or 1/4 of the maximum capacity of a TLS record. */ MOCK_IMPL(int, channel_should_write_to_kernel, (outbuf_table_t *table, channel_t *chan))