kerberos: Avoid needless conversions between SYSTEMTIME and FILETIME.

Signed-off-by: Dmitry Timoshkov <dmitry@baikal.ru>
Signed-off-by: Hans Leidekker <hans@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
Dmitry Timoshkov 2018-08-28 11:56:42 +08:00 committed by Alexandre Julliard
parent 96a6053fed
commit 33732facd6
1 changed files with 2 additions and 3 deletions

View File

@ -751,12 +751,11 @@ static void trace_gss_status( OM_uint32 major_status, OM_uint32 minor_status )
static void expirytime_gss_to_sspi( OM_uint32 expirytime, TimeStamp *timestamp )
{
SYSTEMTIME time;
FILETIME filetime;
ULARGE_INTEGER tmp;
GetLocalTime( &time );
SystemTimeToFileTime( &time, &filetime );
GetSystemTimeAsFileTime( &filetime );
FileTimeToLocalFileTime( &filetime, &filetime );
tmp.QuadPart = ((ULONGLONG)filetime.dwLowDateTime | (ULONGLONG)filetime.dwHighDateTime << 32) + expirytime;
timestamp->LowPart = tmp.QuadPart;
timestamp->HighPart = tmp.QuadPart >> 32;