diff options
author | Jared Adams <jaxad0127@gmail.com> | 2010-08-02 21:05:05 -0600 |
---|---|---|
committer | Jared Adams <jaxad0127@gmail.com> | 2010-08-02 21:05:05 -0600 |
commit | 60f0f47c81eefb91863549d3dc37aa58422e3675 (patch) | |
tree | 8dbe2c15e6f9096fdb7147f882086e95e900621d /src/net/connectionhandler.cpp | |
parent | eaa8288a73872cb8d8b3d0b3455d79ce2579f438 (diff) | |
download | manaserv-60f0f47c81eefb91863549d3dc37aa58422e3675.tar.gz manaserv-60f0f47c81eefb91863549d3dc37aa58422e3675.tar.bz2 manaserv-60f0f47c81eefb91863549d3dc37aa58422e3675.tar.xz manaserv-60f0f47c81eefb91863549d3dc37aa58422e3675.zip |
Fix enet version check
Tested-by: BaseBallBoy
Diffstat (limited to 'src/net/connectionhandler.cpp')
-rw-r--r-- | src/net/connectionhandler.cpp | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/src/net/connectionhandler.cpp b/src/net/connectionhandler.cpp index 6aa58569..986d9dec 100644 --- a/src/net/connectionhandler.cpp +++ b/src/net/connectionhandler.cpp @@ -40,19 +40,17 @@ bool ConnectionHandler::startListen(enet_uint16 port, enet_address_set_host(&address, listenHost.c_str()); LOG_INFO("Listening on port " << port << "..."); -#if ENET_VERSION_MAJOR != 1 -#error Unsuported enet version! -#elif ENET_VERSION_MINOR < 3 +#ifdef ENET_VERSION_MAJOR host = enet_host_create( &address /* the address to bind the server host to */, Configuration::getValue("net_maxClients", 1000) /* allowed connections */, + 0 /* unlimited channel count */, 0 /* assume any amount of incoming bandwidth */, 0 /* assume any amount of outgoing bandwidth */); #else host = enet_host_create( &address /* the address to bind the server host to */, Configuration::getValue("net_maxClients", 1000) /* allowed connections */, - 0 /* unlimited channel count */, 0 /* assume any amount of incoming bandwidth */, 0 /* assume any amount of outgoing bandwidth */); #endif |