mirror of
https://github.com/reactos/wine.git
synced 2024-11-24 12:20:07 +00:00
kernel32: Implemented GetTickCount64.
This commit is contained in:
parent
6544d9ee3e
commit
40fb7ca168
@ -636,6 +636,7 @@
|
||||
@ stdcall GetThreadSelectorEntry(long long ptr)
|
||||
@ stdcall GetThreadTimes(long ptr ptr ptr ptr)
|
||||
@ stdcall GetTickCount()
|
||||
@ stdcall -ret64 GetTickCount64()
|
||||
@ stdcall GetTimeFormatA(long long ptr str ptr long)
|
||||
@ stdcall GetTimeFormatW(long long ptr wstr ptr long)
|
||||
@ stdcall GetTimeZoneInformation(ptr)
|
||||
|
@ -46,6 +46,8 @@ WINE_DEFAULT_DEBUG_CHANNEL(process);
|
||||
|
||||
extern int __wine_set_signal_handler(unsigned, int (*)(unsigned));
|
||||
|
||||
static ULONGLONG server_start_time;
|
||||
|
||||
/***********************************************************************
|
||||
* KERNEL thread initialisation routine
|
||||
*/
|
||||
@ -112,12 +114,16 @@ static void set_entry_point( HMODULE module, const char *name, DWORD rva )
|
||||
static BOOL process_attach( HMODULE module )
|
||||
{
|
||||
SYSTEM_INFO si;
|
||||
SYSTEM_TIMEOFDAY_INFORMATION ti;
|
||||
RTL_USER_PROCESS_PARAMETERS *params = NtCurrentTeb()->Peb->ProcessParameters;
|
||||
|
||||
/* FIXME: should probably be done in ntdll */
|
||||
GetSystemInfo( &si );
|
||||
NtCurrentTeb()->Peb->NumberOfProcessors = si.dwNumberOfProcessors;
|
||||
|
||||
NtQuerySystemInformation( SystemTimeOfDayInformation, &ti, sizeof(ti), NULL );
|
||||
server_start_time = ti.liKeBootTime.QuadPart;
|
||||
|
||||
/* Setup registry locale information */
|
||||
LOCALE_InitRegistry();
|
||||
|
||||
@ -236,6 +242,18 @@ INT WINAPI MulDiv( INT nMultiplicand, INT nMultiplier, INT nDivisor)
|
||||
}
|
||||
|
||||
|
||||
/******************************************************************************
|
||||
* GetTickCount64 (KERNEL32.@)
|
||||
*/
|
||||
ULONGLONG WINAPI GetTickCount64(void)
|
||||
{
|
||||
LARGE_INTEGER now;
|
||||
|
||||
NtQuerySystemTime( &now );
|
||||
return (now.QuadPart - server_start_time) / 10000;
|
||||
}
|
||||
|
||||
|
||||
/***********************************************************************
|
||||
* GetTickCount (KERNEL32.@)
|
||||
*
|
||||
@ -254,5 +272,5 @@ INT WINAPI MulDiv( INT nMultiplicand, INT nMultiplier, INT nDivisor)
|
||||
*/
|
||||
DWORD WINAPI GetTickCount(void)
|
||||
{
|
||||
return NtGetTickCount();
|
||||
return GetTickCount64();
|
||||
}
|
||||
|
@ -1679,6 +1679,7 @@ DWORD WINAPI GetTempPathA(DWORD,LPSTR);
|
||||
DWORD WINAPI GetTempPathW(DWORD,LPWSTR);
|
||||
#define GetTempPath WINELIB_NAME_AW(GetTempPath)
|
||||
DWORD WINAPI GetTickCount(void);
|
||||
ULONGLONG WINAPI GetTickCount64(void);
|
||||
DWORD WINAPI GetTimeZoneInformation(LPTIME_ZONE_INFORMATION);
|
||||
BOOL WINAPI GetThreadContext(HANDLE,CONTEXT *);
|
||||
INT WINAPI GetThreadPriority(HANDLE);
|
||||
|
Loading…
Reference in New Issue
Block a user