libmicrohttpd

HTTP/1.x server C library (MHD 1.x, stable)
Log | Files | Refs | Submodules | README | LICENSE

commit 4d7d35d8a29b70659688db209b19db949994bc59
parent 66e6f4f2e965682d1cabaf217d6db40beb0877e1
Author: Evgeny Grin (Karlson2k) <k2k@narod.ru>
Date:   Sat, 21 Aug 2021 18:34:54 +0300

build_header_response(): clarified comment

Diffstat:
Msrc/microhttpd/connection.c | 7++++---
1 file changed, 4 insertions(+), 3 deletions(-)

diff --git a/src/microhttpd/connection.c b/src/microhttpd/connection.c @@ -1872,9 +1872,10 @@ build_header_response (struct MHD_Connection *connection) else if (MHD_CONN_USE_KEEPALIVE == c->keepalive) { use_conn_close = false; - /* As "Keep-Alive" is default for HTTP/1.1, add "Connection: keep-alive" - * header only if explicitly requested by app (by using response flag), - * if request is HTTP/1.0 or if reply is HTTP/1.0. */ + /* Add "Connection: keep-alive" if request is HTTP/1.0 or + * if reply is HTTP/1.0 + * For HTTP/1.1 add header only if explicitly requested by app + * (by response flag), as "Keep-Alive" is default for HTTP/1.1. */ if ((0 != (r->flags & MHD_RF_SEND_KEEP_ALIVE_HEADER)) || (MHD_HTTP_VER_1_0 == c->http_ver) || (0 != (r->flags & MHD_RF_HTTP_1_0_SERVER)))