Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Jun 23, 2009, 2:12:44 AM (15 years ago)
Author:
rgrieder
Message:

Cleanup in network plus a few dependency reductions (no enet-function inlines, using enum PacketFlag instead of the enet version)

File:
1 edited

Legend:

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

    r3203 r3209  
    2929#include "ClientConnection.h"
    3030
    31 #include <iostream>
    3231#include <cassert>
    33 
     32#include <enet/enet.h>
    3433#include "util/Debug.h"
    3534
     
    4342
    4443  ClientConnection::ClientConnection():
    45     server_(NULL),
    46     established_(false)
     44    established_(false),
     45    server_(NULL)
    4746  {
    4847    this->serverAddress_ = new ENetAddress();
     
    5655      closeConnection();
    5756    delete this->serverAddress_; // surely was created
     57  }
     58
     59  void ClientConnection::setServerAddress( const std::string& serverAddress ) {
     60    enet_address_set_host (this->serverAddress_, serverAddress.c_str());
     61  }
     62
     63  void ClientConnection::setPort( unsigned int port ) {
     64    this->serverAddress_->port = port;
    5865  }
    5966
Note: See TracChangeset for help on using the changeset viewer.