Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 9426 in orxonox.OLD for branches/proxy/src/lib/network/proxy


Ignore:
Timestamp:
Jul 24, 2006, 2:49:33 PM (18 years ago)
Author:
bensch
Message:

cleaner ip inclusion

Location:
branches/proxy/src/lib/network/proxy
Files:
2 edited

Legend:

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

    r9416 r9426  
    5151
    5252  // remove all unused proxy data again
    53   for( int i = 0; i < this->proxies.size(); i++)
     53  for(unsigned int i = 0; i < this->proxies.size(); i++)
    5454  {
    55     IPaddress* ip = this->proxies.back();
     55    IP ip = this->proxies.back();
    5656    this->proxies.pop_back();
    57     delete ip;
    5857  }
    5958}
     
    139138    return;
    140139
    141   IPaddress *ip = new IPaddress;
     140  IP ip(proxyAddr, 9999);
     141  printf("========== ");
     142  ip.debug();
    142143
    143   SDLNet_ResolveHost( ip, proxyAddr.c_str(), 9999 );
    144 
    145   this->proxies.push_back(ip);
     144  this->proxies.push_back(ip);//IP(proxyAddr, 9999));
    146145}
    147146
  • branches/proxy/src/lib/network/proxy/network_settings.h

    r9410 r9426  
    4848    void setProxyAddr(const std::string& proxyAddr);
    4949    /** @returns the list of proxy servers from the init file */
    50     inline std::vector<IPaddress*>* getProxyList() { return &this->proxies; }
     50    inline std::vector<IP>* getProxyList() { return &this->proxies; }
    5151
    5252
     
    6161    float                        maxPlayerSaturation;     //!< the saturation level from where on the proxy server should be activated
    6262
    63     std::vector<IPaddress*>      proxies;                 //!< all registered proxies
     63    std::vector<IP>              proxies;                 //!< all registered proxies
    6464    IP                           masterServer;            //!< master server ip address
    6565
Note: See TracChangeset for help on using the changeset viewer.