Computer Powers Off Unexpectedly If a Program Calls the ExitWindowsEx() Function (819037)



The information in this article applies to:

  • Microsoft Windows Server 2003, 64-Bit Datacenter Edition
  • Microsoft Windows Server 2003, 64-Bit Enterprise Edition
  • Microsoft Windows Server 2003, Datacenter Edition
  • Microsoft Windows Server 2003, Enterprise Edition
  • Microsoft Windows Server 2003, Standard Edition
  • Microsoft Windows Server 2003, Web Edition
  • Microsoft Windows XP Home Edition SP1
  • Microsoft Windows XP Professional SP1
  • Microsoft Windows Small Business Server 2003, Standard Edition
  • Microsoft Windows Small Business Server 2003, Premium Edition

SYMPTOMS

If a program calls the ExitWindowsEx() function and the EWX_SHUTDOWN flag is used, Windows may turn off the power instead of displaying the "It is now safe to power off your computer" message.

CAUSE

In Windows XP Service Pack 1 (SP1) and the Windows Server 2003 family, Windows treats the EWX_SHUTDOWN flag the same as the EWX_POWEROFF flag. That is, Windows turns off the power after it shuts down the computer if the computer supports the power-off feature.

MORE INFORMATION

This behavior also occurs if the InitiateSystemShutdownEx() function is used to shut down the computer if the computer supports the power-off feature.

Modification Type:MajorLast Reviewed:3/1/2004
Keywords:kbprb KB819037