aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/microhttpd/connection.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/microhttpd/connection.c b/src/microhttpd/connection.c
index b3ef9441..9b8d3e2b 100644
--- a/src/microhttpd/connection.c
+++ b/src/microhttpd/connection.c
@@ -1995,6 +1995,16 @@ transmit_error_response (struct MHD_Connection *connection,
1995 } 1995 }
1996 connection->state = MHD_CONNECTION_FOOTERS_RECEIVED; 1996 connection->state = MHD_CONNECTION_FOOTERS_RECEIVED;
1997 connection->read_closed = true; 1997 connection->read_closed = true;
1998 if (0 != connection->read_buffer_size)
1999 {
2000 /* Read buffer is not needed anymore, discard it
2001 * to free some space for error response. */
2002 connection->read_buffer = MHD_pool_reallocate(connection->pool,
2003 connection->read_buffer,
2004 connection->read_buffer_size,
2005 0);
2006 connection->read_buffer_size = 0;
2007 }
1998#ifdef HAVE_MESSAGES 2008#ifdef HAVE_MESSAGES
1999 MHD_DLOG (connection->daemon, 2009 MHD_DLOG (connection->daemon,
2000 _("Error processing request (HTTP response code is %u (`%s')). Closing connection.\n"), 2010 _("Error processing request (HTTP response code is %u (`%s')). Closing connection.\n"),