[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[GNUnet-SVN] r6645 - libmicrohttpd/src/daemon
From: |
gnunet |
Subject: |
[GNUnet-SVN] r6645 - libmicrohttpd/src/daemon |
Date: |
Fri, 28 Mar 2008 17:38:49 -0600 (MDT) |
Author: grothoff
Date: 2008-03-28 17:38:49 -0600 (Fri, 28 Mar 2008)
New Revision: 6645
Modified:
libmicrohttpd/src/daemon/connection.c
Log:
fixing connection clean up issue
Modified: libmicrohttpd/src/daemon/connection.c
===================================================================
--- libmicrohttpd/src/daemon/connection.c 2008-03-28 22:57:09 UTC (rev
6644)
+++ libmicrohttpd/src/daemon/connection.c 2008-03-28 23:38:49 UTC (rev
6645)
@@ -1626,7 +1626,14 @@
case MHD_CONNECTION_INIT:
line = get_next_header_line (connection);
if (line == NULL)
- break;
+ {
+ if (connection->read_closed)
+ {
+ connection->state = MHD_CONNECTION_CLOSED;
+ continue;
+ }
+ break;
+ }
if (MHD_NO == parse_initial_message_line (connection, line))
connection->state = MHD_CONNECTION_CLOSED;
else
@@ -1635,7 +1642,14 @@
case MHD_CONNECTION_URL_RECEIVED:
line = get_next_header_line (connection);
if (line == NULL)
- break;
+ {
+ if (connection->read_closed)
+ {
+ connection->state = MHD_CONNECTION_CLOSED;
+ continue;
+ }
+ break;
+ }
if (strlen (line) == 0)
{
connection->state = MHD_CONNECTION_HEADERS_RECEIVED;
@@ -1653,7 +1667,14 @@
case MHD_CONNECTION_HEADER_PART_RECEIVED:
line = get_next_header_line (connection);
if (line == NULL)
- break;
+ {
+ if (connection->read_closed)
+ {
+ connection->state = MHD_CONNECTION_CLOSED;
+ continue;
+ }
+ break;
+ }
if (MHD_NO ==
process_broken_line (connection, line, MHD_HEADER_KIND))
continue;
@@ -1712,7 +1733,14 @@
case MHD_CONNECTION_BODY_RECEIVED:
line = get_next_header_line (connection);
if (line == NULL)
- break;
+ {
+ if (connection->read_closed)
+ {
+ connection->state = MHD_CONNECTION_CLOSED;
+ continue;
+ }
+ break;
+ }
if (strlen (line) == 0)
{
connection->state = MHD_CONNECTION_FOOTERS_RECEIVED;
@@ -1730,7 +1758,14 @@
case MHD_CONNECTION_FOOTER_PART_RECEIVED:
line = get_next_header_line (connection);
if (line == NULL)
- break;
+ {
+ if (connection->read_closed)
+ {
+ connection->state = MHD_CONNECTION_CLOSED;
+ continue;
+ }
+ break;
+ }
if (MHD_NO ==
process_broken_line (connection, line, MHD_FOOTER_KIND))
continue;
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [GNUnet-SVN] r6645 - libmicrohttpd/src/daemon,
gnunet <=