Author: cwittich
Date: Tue May 5 08:07:08 2015
New Revision: 67557
URL:
http://svn.reactos.org/svn/reactos?rev=67557&view=rev
Log:
[NTVDM]
don't try to deference an uninitialized Timer
Modified:
trunk/reactos/subsystems/mvdm/ntvdm/clock.c
Modified: trunk/reactos/subsystems/mvdm/ntvdm/clock.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/mvdm/ntvdm/cloc…
==============================================================================
--- trunk/reactos/subsystems/mvdm/ntvdm/clock.c [iso-8859-1] (original)
+++ trunk/reactos/subsystems/mvdm/ntvdm/clock.c [iso-8859-1] Tue May 5 08:07:08 2015
@@ -188,8 +188,12 @@
VOID DestroyHardwareTimer(PHARDWARE_TIMER Timer)
{
- if (Timer->Flags & HARDWARE_TIMER_ENABLED)
RemoveEntryList(&Timer->Link);
- RtlFreeHeap(RtlGetProcessHeap(), 0, Timer);
+ if (Timer)
+ {
+ if (Timer->Flags & HARDWARE_TIMER_ENABLED)
RemoveEntryList(&Timer->Link);
+ RtlFreeHeap(RtlGetProcessHeap(), 0, Timer);
+ Timer = NULL;
+ }
}
BOOLEAN ClockInitialize(VOID)