mirror of
https://github.com/reactos/reactos.git
synced 2025-08-04 23:05:41 +00:00
Fixed the setting of the real time clock.
svn path=/trunk/; revision=3859
This commit is contained in:
parent
cd35c38aa0
commit
d008835685
1 changed files with 4 additions and 2 deletions
|
@ -1,4 +1,4 @@
|
||||||
/* $Id: time.c,v 1.14 2002/09/08 10:23:19 chorns Exp $
|
/* $Id: time.c,v 1.15 2002/12/09 20:13:12 hbirr Exp $
|
||||||
*
|
*
|
||||||
* COPYRIGHT: See COPYING in the top level directory
|
* COPYRIGHT: See COPYING in the top level directory
|
||||||
* PROJECT: ReactOS kernel
|
* PROJECT: ReactOS kernel
|
||||||
|
@ -57,6 +57,7 @@ NtSetSystemTime (IN PLARGE_INTEGER UnsafeNewSystemTime,
|
||||||
NTSTATUS Status;
|
NTSTATUS Status;
|
||||||
LARGE_INTEGER OldSystemTime;
|
LARGE_INTEGER OldSystemTime;
|
||||||
LARGE_INTEGER NewSystemTime;
|
LARGE_INTEGER NewSystemTime;
|
||||||
|
TIME_FIELDS TimeFields;
|
||||||
|
|
||||||
/* FIXME: Check for SeSystemTimePrivilege */
|
/* FIXME: Check for SeSystemTimePrivilege */
|
||||||
|
|
||||||
|
@ -71,7 +72,8 @@ NtSetSystemTime (IN PLARGE_INTEGER UnsafeNewSystemTime,
|
||||||
{
|
{
|
||||||
KeQuerySystemTime(&OldSystemTime);
|
KeQuerySystemTime(&OldSystemTime);
|
||||||
}
|
}
|
||||||
HalSetRealTimeClock ((PTIME_FIELDS)&NewSystemTime);
|
RtlTimeToTimeFields (&NewSystemTime, &TimeFields);
|
||||||
|
HalSetRealTimeClock (&TimeFields);
|
||||||
|
|
||||||
if (UnsafeOldSystemTime != NULL)
|
if (UnsafeOldSystemTime != NULL)
|
||||||
{
|
{
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue