views:

726

answers:

3

When I run a test harness through the Visual Studio 2005 debugger, it creates a console window every time I run it.

In the past, the console window would close automatically when the test harness process terminated, but now I'm finding that the console window is hanging around afterwards.

After the test harness terminates:

  • I cannot close the console window by clicking the close (x) button on the top-right
  • The test harness process doesn't exist anymore in Task Manager

So I cannot seem to kill these console windows.

Does anyone know:

  1. How these console windows can exist without a managing process?
  2. How can I can kill these console windows?

Rebooting is obviously an option, but there must be another way.

A: 

Same problem here. Overhere even rebooting is not an option as Windows cannot close the console windows itself. I even tried shutdown -f -t 01

But the only way to shutdown Windows is the powerbutton. Does someone have the same problem / solution?

Johan
+2  A: 

It's a known bug in windows, introduced with KB978037 security patch.

You can find out more here http://blogs.msdn.com/debugger/archive/2010/03/11/help-my-console-windows-won-t-go-away.aspx

and here http://social.msdn.microsoft.com/Forums/en/vsdebug/thread/e6d4a4f5-7002-401a-90e1-6174d7f9e3ca

Ivan
Bingo! [.......]
LeopardSkinPillBoxHat
A: 

In Windows, "Administrator" is not the highest level user. Some processes/files/directories are only accessible by the "SYSTEM" user. See: http://hackspc.com/how-to-become-the-system-user-in-windows-xp/

This may be the reason why it is unkillable.

an0nym0usc0ward