mirror of
https://github.com/emikulic/darkhttpd.git
synced 2023-08-10 21:13:08 +03:00
. Use goto instead of code duplication.
This commit is contained in:
parent
5563889b66
commit
db6517c62d
@ -1818,6 +1818,7 @@ static void httpd_poll(void)
|
|||||||
switch (conn->state)
|
switch (conn->state)
|
||||||
{
|
{
|
||||||
case RECV_REQUEST:
|
case RECV_REQUEST:
|
||||||
|
recv_request:
|
||||||
MAX_FD_SET(conn->socket, &recv_set);
|
MAX_FD_SET(conn->socket, &recv_set);
|
||||||
bother_with_timeout = 1;
|
bother_with_timeout = 1;
|
||||||
break;
|
break;
|
||||||
@ -1840,8 +1841,7 @@ static void httpd_poll(void)
|
|||||||
{
|
{
|
||||||
recycle_connection(conn);
|
recycle_connection(conn);
|
||||||
/* And enqueue as RECV_REQUEST. */
|
/* And enqueue as RECV_REQUEST. */
|
||||||
MAX_FD_SET(conn->socket, &recv_set);
|
goto recv_request;
|
||||||
bother_with_timeout = 1;
|
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user