MCPcopy Create free account
hub / github.com/defold/defold / timeout_gettime

Function timeout_gettime

engine/script/src/luasocket/timeout.c:125–133  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

123\*-------------------------------------------------------------------------*/
124#ifdef _WIN32
125double timeout_gettime(void) {
126 FILETIME ft;
127 double t;
128 GetSystemTimeAsFileTime(&ft);
129 /* Windows file time (time since January 1, 1601 (UTC)) */
130 t = ft.dwLowDateTime/1.0e7 + ft.dwHighDateTime*(4294967296.0/1.0e7);
131 /* convert to Unix Epoch time (time since January 1, 1970 (UTC)) */
132 return (t - 11644473600.0);
133}
134#else
135double timeout_gettime(void) {
136 struct timeval v;

Callers 9

buffer_initFunction · 0.85
buffer_meth_getstatsFunction · 0.85
buffer_meth_setstatsFunction · 0.85
buffer_meth_sendFunction · 0.85
buffer_meth_receiveFunction · 0.85
timeout_getFunction · 0.85
timeout_getretryFunction · 0.85
timeout_markstartFunction · 0.85
timeout_lua_gettimeFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected