Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 9462 in orxonox.OLD for branches/proxy/src


Ignore:
Timestamp:
Jul 25, 2006, 6:01:47 PM (18 years ago)
Author:
patrick
Message:

proxy server connections: listening on a seperate server socket, better this way

Location:
branches/proxy/src
Files:
7 edited

Legend:

Unmodified
Added
Removed
  • branches/proxy/src/lib/network/network_stream.cc

    r9459 r9462  
    360360  //check for new connections
    361361
    362   NetworkSocket* tempNetworkSocket = serverSocket->getNewClientSocket();
     362  NetworkSocket* tempNetworkSocket = serverSocket->getNewSocket();
    363363
    364364  // we got new network node
  • branches/proxy/src/lib/network/server_socket.h

    r9459 r9462  
    2525
    2626    virtual bool listen( unsigned int port ) = 0;
    27     virtual NetworkSocket* getNewClientSocket( void ) = 0;
    28 //     virtual NetworkSocket* getNewClientSocket( void ) = 0;
     27    virtual NetworkSocket* getNewSocket( void ) = 0;
    2928    virtual void close() = 0;
    3029    virtual void update() = 0;
  • branches/proxy/src/lib/network/tcp_server_socket.cc

    r9460 r9462  
    105105
    106106
    107 NetworkSocket* TcpServerSocket::getNewClientSocket( )
     107NetworkSocket* TcpServerSocket::getNewSocket( )
    108108{
    109109  if ( !listenSocket )
     
    127127
    128128
    129 NetworkSocket* TcpServerSocket::getNewProxySocket( )
    130 {
    131     return NULL;
    132 }
    133 
    134129
    135130void TcpServerSocket::close( )
  • branches/proxy/src/lib/network/tcp_server_socket.h

    r9460 r9462  
    2525
    2626    virtual bool listen( unsigned int port );
    27     virtual NetworkSocket* getNewClientSocket( void );
    28     virtual NetworkSocket* getNewProxySocket( void );
     27    virtual NetworkSocket* getNewSocket( void );
    2928    virtual void close();
    3029    virtual void update() {};
  • branches/proxy/src/lib/network/udp_server_socket.cc

    r9461 r9462  
    8282 *  only clients connect to this socket
    8383 */
    84 NetworkSocket * UdpServerSocket::getNewClientSocket( void )
     84NetworkSocket * UdpServerSocket::getNewSocket( void )
    8585{
    8686  NetworkSocket * result = NULL;
     
    303303          break;
    304304
    305       initUser( userId, packet->address, packet->data[0] & 0xFC );
     305      this->initUser( userId, packet->address, packet->data[0] & 0xFC );
    306306      UdpSocket * sock = new UdpSocket( this, packet->address, userId, packet->data[0] & 0xFC );
    307307      newSocketList.push_back( sock );
  • branches/proxy/src/lib/network/udp_server_socket.h

    r9461 r9462  
    5656    /* server socket manipulations */
    5757    virtual bool listen( unsigned int port );
    58     virtual NetworkSocket* getNewClientSocket( void );
    59     virtual NetworkSocket* getNewProxySocket( void );
     58    virtual NetworkSocket* getNewSocket( void );
    6059    virtual void close();
    61 
    6260
    6361    virtual void update();
     
    7674
    7775  private:
    78     UDPsocket          socket;           //!< will be uses to send/recieve data
     76    UDPsocket          socket;           //!< will be used to send/recieve data to/from clients
    7977    UDPpacket *        packet;           //!< packet structure to recieve packet
    8078    PacketBuffer       packetBuffer;     //!< will store recieved packets for UdpSockets
  • branches/proxy/src/subprojects/network/network_unit_test.cc

    r9459 r9462  
    5050  {
    5151    server.update();
    52     server1 = server.getNewClientSocket();
     52    server1 = server.getNewSocket();
    5353  }
    5454 
     
    6161  {
    6262    server.update();
    63     server2 = server.getNewClientSocket();
     63    server2 = server.getNewSocket();
    6464  }
    6565
Note: See TracChangeset for help on using the changeset viewer.