Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Jun 21, 2009, 12:27:19 AM (15 years ago)
Author:
scheusso
Message:

rest of the cleanup ( mostly client connection handling)
network is now single-threaded ( only in order to become multithreaded again, but thats another story ;) )

File:
1 edited

Legend:

Unmodified
Added
Removed
  • code/branches/netp5/src/network/ServerConnection.cc

    r3201 r3202  
    5353
    5454  bool ServerConnection::openListener() {
    55     enet_initialize();
    56     atexit(enet_deinitialize);
    5755    this->host_ = enet_host_create(this->bindAddress_, NETWORK_MAX_CONNECTIONS, 0, 0);
    5856    if ( this->host_ == NULL )
     
    9189  void ServerConnection::disconnectClient(ClientInformation *client)
    9290  {
    93     disconnectPeer( client->getPeer() );
     91    Connection::disconnectPeer( client->getPeer() );
    9492    delete client;
    9593  }
    9694 
    97   void ServerConnection::disconnectClient( ENetEvent* event )
     95  void ServerConnection::disconnectPeer( ENetEvent* event )
    9896  {
    9997    COUT(4) << "removing client from list" << std::endl;
     
    115113    ClientInformation *temp = ClientInformation::getBegin();
    116114    while(temp!=0){
    117       disconnectPeer( temp->getPeer() );
     115      disconnectPeer( &event );
    118116      temp = temp->next();
    119117    }
Note: See TracChangeset for help on using the changeset viewer.