Re: [Quickfix-developers] SocketAcceptor listens on all local interfaces, should be configurable
Brought to you by:
orenmnero
From: <OM...@th...> - 2003-04-03 08:59:31
|
Yes, a patch would be great. --oren |---------+-----------------------------------------------> | | Joerg Thoennes | | | <Joe...@ma...> | | | Sent by: | | | qui...@li...ur| | | ceforge.net | | | | | | | | | 04/03/2003 02:09 AM | | | Please respond to Joerg.Thoennes | | | | |---------+-----------------------------------------------> >--------------------------------------------------------------------= --------------------------| | = | | To: developers QuickFIX <qui...@li...ur= ceforge.net> | | cc: = | | Subject: [Quickfix-developers] SocketAcceptor listens on all= local interfaces, should | | be configurable = | >--------------------------------------------------------------------= --------------------------| Hi, looking at documentation for the configuration of the Acceptor, I see t= hat only the listen port can be configured. The source reveals that the SocketAccept= or listens on all local interfaces (line 116): 108 SocketServer::SocketServer( int port, int timeout ) 109 : m_port( port ), m_monitor( timeout ) 110 { 111 m_socket =3D socket( PF_INET, SOCK_STREAM, 0 ); 112 if ( m_socket < 0 ) throw std::exception(); 113 114 m_address.sin_family =3D PF_INET; 115 m_address.sin_port =3D htons( port ); 116 m_address.sin_addr.s_addr =3D INADDR_ANY; 117 m_socklen =3D sizeof( m_address ); 118 119 socket_setsockopt( m_socket ); 120 if ( !bind() ) throw std::exception(); 121 if ( !listen() ) throw std::exception(); 122 m_monitor.add( m_socket ); 123 } The backlog is currently configured to the maximum value. This could be= also configurable. Since we work with virtual interface in the production environment, it would be important if we could specify a distinct host/IP address to listen on. The defaul= t could remain e.g. "*" which could mean INADDR_ANY. Oren, shall I provide a patch to implement this? Cheers, J=F6rg -- Joerg Thoennes http://macd.com Tel.: +49 (0)241 44597-24 Macdonald Associates GmbH Fax : +49 (0)241 44597-10 Lothringer Str. 52, D-52070 Aachen ------------------------------------------------------- This SF.net email is sponsored by: ValueWeb: Dedicated Hosting for just $79/mo with 500 GB of bandwidth! No other company gives more support or power for your dedicated server http://click.atdmt.com/AFF/go/sdnxxaff00300020aff/direct/01/ _______________________________________________ Quickfix-developers mailing list Qui...@li... https://lists.sourceforge.net/lists/listinfo/quickfix-developers = |