]> git.ipfire.org Git - thirdparty/dovecot/core.git/commitdiff
lib-http: http-server: Flush output after sending 500 error for aborted request
authorTimo Sirainen <timo.sirainen@dovecot.fi>
Wed, 23 May 2018 11:36:55 +0000 (14:36 +0300)
committerTimo Sirainen <timo.sirainen@dovecot.fi>
Wed, 4 Jul 2018 18:33:06 +0000 (18:33 +0000)
It probably doesn't make a difference, but it's a bit clearer what the
intent is.

src/lib-http/http-server-request.c

index 597912151a5b37bbd2155d1b1713dc723cb47f0b..b548b6abf92fe657d5f359c4b487d6b9b9584d6b 100644 (file)
@@ -190,8 +190,9 @@ void http_server_request_abort(struct http_server_request **_req,
                                                "Content-Length: 0\r\n"
                                                "\r\n";
 
-                                       (void)o_stream_send(conn->conn.output,
+                                       o_stream_nsend(conn->conn.output,
                                                response, strlen(response));
+                                       (void)o_stream_flush(conn->conn.output);
                                }
 
                                /* close the connection */