From: Stephan Bosch Date: Fri, 8 May 2020 14:18:29 +0000 (+0200) Subject: lib-http: test-http-client-errors: "reply payload" test - Make server announce that... X-Git-Tag: 2.3.11.2~100 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=f6ef63aa9d99d96aeef19c2664605dab4ef68987;p=thirdparty%2Fdovecot%2Fcore.git lib-http: test-http-client-errors: "reply payload" test - Make server announce that connection is closed. This prevents race condition between connection closure and client trying to reuse the connection. --- diff --git a/src/lib-http/test-http-client-errors.c b/src/lib-http/test-http-client-errors.c index 717946f5d0..b6e9489af1 100644 --- a/src/lib-http/test-http-client-errors.c +++ b/src/lib-http/test-http-client-errors.c @@ -1031,6 +1031,7 @@ static void test_retry_payload_input(struct server_connection *conn) i_debug("Expected payload received"); o_stream_nsend_str(conn->conn.output, "HTTP/1.1 500 Oh no!\r\n" + "Connection: close\r\n" "Content-Length: 17\r\n" "\r\n" "Expected result\r\n"); @@ -1039,6 +1040,7 @@ static void test_retry_payload_input(struct server_connection *conn) str_sanitize(line, 128)); o_stream_nsend_str(conn->conn.output, "HTTP/1.1 501 Oh no!\r\n" + "Connection: close\r\n" "Content-Length: 19\r\n" "\r\n" "Unexpected result\r\n");