int check_pending(connection_t *connection, int timeout_s, int *got_data)
{
/* a non-blocking socket will block if there is 0 bytes available on the socket,
int check_pending(connection_t *connection, int timeout_s, int *got_data)
{
/* a non-blocking socket will block if there is 0 bytes available on the socket,