aboutsummaryrefslogtreecommitdiffhomepage
path: root/host.c
diff options
context:
space:
mode:
authorlsalzman <[email protected]>2013-08-09 09:41:57 +0300
committerlsalzman <[email protected]>2013-08-09 09:41:57 +0300
commit1658cf3a9527c47a76c79efbe477bbbe3350d847 (patch)
tree4168ad2c864857112114b8b317168be3097d0c53 /host.c
parent4697a58d53ca1027a78f7f36a2544ad653e2aa09 (diff)
downloadenet-1658cf3a9527c47a76c79efbe477bbbe3350d847.tar.gz
enet-1658cf3a9527c47a76c79efbe477bbbe3350d847.zip
stub out enet_host_random_seed()
Diffstat (limited to 'host.c')
-rw-r--r--host.c7
1 files changed, 1 insertions, 6 deletions
diff --git a/host.c b/host.c
index f07d714..8fdb160 100644
--- a/host.c
+++ b/host.c
@@ -4,7 +4,6 @@
*/
#define ENET_BUILDING_LIB 1
#include <string.h>
-#include <time.h>
#include "enet/enet.h"
/** @defgroup host ENet host functions
@@ -76,11 +75,7 @@ enet_host_create (const ENetAddress * address, size_t peerCount, size_t channelL
channelLimit = ENET_PROTOCOL_MINIMUM_CHANNEL_COUNT;
host -> randomSeed = (enet_uint32) (size_t) host;
-#ifdef WIN32
- host -> randomSeed += (enet_uint32) timeGetTime();
-#else
- host -> randomSeed += (enet_uint32) time(NULL);
-#endif
+ host -> randomSeed += enet_host_random_seed ();
host -> randomSeed = (host -> randomSeed << 16) | (host -> randomSeed >> 16);
host -> channelLimit = channelLimit;
host -> incomingBandwidth = incomingBandwidth;