diff --git a/src/socket_connection.c b/src/socket_connection.c index f9245b0f6..bae9c4fc9 100644 --- a/src/socket_connection.c +++ b/src/socket_connection.c @@ -93,6 +93,7 @@ struct connection { /** list of socket connections */ static linked_list_t connections = NULL; +static linked_list_t parked = NULL; /** client packet handler */ @@ -528,10 +529,10 @@ int socket_connection_close_unix(connection_t * connection){ } /** - * try to dispatch packet for all "parked" connections. start at random point for fairness + * try to dispatch packet for all "parked" connections. * if dispatch is successful, a connection is added again to run loop */ -void socket_connection_retry_parked_random(){ +void socket_connection_retry_parked(){ // re-try dispatching packet // int dispatch_err = (*socket_connection_packet_callback)(conn, READ_BT_16( conn->buffer, 0), READ_BT_16( conn->buffer, 2), // &conn->buffer[sizeof(packet_header_t)], READ_BT_16( conn->buffer, 4)); diff --git a/src/socket_connection.h b/src/socket_connection.h index 6e94b2984..b68384cf5 100644 --- a/src/socket_connection.h +++ b/src/socket_connection.h @@ -102,7 +102,7 @@ void socket_connection_send_packet(connection_t *connection, uint16_t packet_typ void socket_connection_send_packet_all(uint16_t type, uint16_t channel, uint8_t *packet, uint16_t size); /** - * try to dispatch packet for all "parked" connections. start at random point for fairness + * try to dispatch packet for all "parked" connections. * if dispatch is successful, a connection is added again to run loop */ -void socket_connection_retry_parked_random(); +void socket_connection_retry_parked();