src/mca/oob/tcp/oob_tcp_listener.c
/*
 * Handler for accepting connections from the listen thread
 */
Handler for accepting connections from the listen thread
Handler for accepting connections from the listen thread
static void connection_handler(int sd, short flags, void *cbdata)
{
    prte_oob_tcp_pending_connection_t *new_connection;
    new_connection = (prte_oob_tcp_pending_connection_t *) cbdata;
    PRTE_ACQUIRE_OBJECT(new_connection);
    prte_output_verbose(4, prte_oob_base_framework.framework_output,
                        "%s connection_handler: working connection "
                        "(%d, %d) %s:%d\n",
                        PRTE_NAME_PRINT(PRTE_PROC_MY_NAME), new_connection->fd, prte_socket_errno,
                        prte_net_get_hostname((struct sockaddr *) &new_connection->addr),
                        prte_net_get_port((struct sockaddr *) &new_connection->addr));
    prte_oob_tcp_module.accept_connection(new_connection->fd,
                                          (struct sockaddr *) &(new_connection->addr));
    PRTE_RELEASE(new_connection);
}
static void connection_handler ( int sd , short flags , void * cbdata ) { prte_oob_tcp_pending_connection_t * new_connection ; new_connection = ( prte_oob_tcp_pending_connection_t * ) cbdata ; PRTE_ACQUIRE_OBJECT ( new_connection ) ; prte_output_verbose ( 4 , prte_oob_base_framework . framework_output , " " " \n " , PRTE_NAME_PRINT ( PRTE_PROC_MY_NAME ) , new_connection -> fd , prte_socket_errno , prte_net_get_hostname ( ( struct sockaddr * ) & new_connection -> addr ) , prte_net_get_port ( ( struct sockaddr * ) & new_connection -> addr ) ) ; prte_oob_tcp_module . accept_connection ( new_connection -> fd , ( struct sockaddr * ) & ( new_connection -> addr ) ) ; PRTE_RELEASE ( new_connection ) ; }
Handler for accepting connections from the listen thread
Handler for accepting connections from the listen thread
/* process the connection */ /* cleanup */