summaryrefslogtreecommitdiff
path: root/modules/enet
diff options
context:
space:
mode:
authorGeorge Marques <george@gmarqu.es>2016-09-03 19:41:36 -0300
committerGeorge Marques <george@gmarqu.es>2016-09-03 19:46:26 -0300
commit5f5db46e8d0a28c3b5ac5fab36c14d3393217bfe (patch)
treeec9bb6c9152927f023063e52218df4ed0626739e /modules/enet
parentc9b82498b4b8de7b5f4c19873421d32ca1749ed2 (diff)
Patch thirdy-party libraries to build for WinRT
- Patch enet code. - Patch OpenSSL code and add shims for unavailable API. - Add extra definition header for Freetype.
Diffstat (limited to 'modules/enet')
-rw-r--r--modules/enet/win32.c13
1 files changed, 13 insertions, 0 deletions
diff --git a/modules/enet/win32.c b/modules/enet/win32.c
index d77fa9a49a..15edd7acbb 100644
--- a/modules/enet/win32.c
+++ b/modules/enet/win32.c
@@ -28,7 +28,9 @@ enet_initialize (void)
return -1;
}
+#ifndef WINRT_ENABLED
timeBeginPeriod (1);
+#endif
return 0;
}
@@ -36,11 +38,22 @@ enet_initialize (void)
void
enet_deinitialize (void)
{
+#ifndef WINRT_ENABLED
timeEndPeriod (1);
+#endif
WSACleanup ();
}
+#ifdef WINRT_ENABLED
+enet_uint32
+timeGetTime() {
+ ULONGLONG ticks = GetTickCount64();
+ return (enet_uint32)ticks;
+}
+#endif
+
+
enet_uint32
enet_host_random_seed (void)
{