How to stop “Just In Time Debugging” messages bloc

2019-01-30 19:55发布

Our buildserver (TeamCity, much recommended), runs our a whole bunch of testsuites on our finished c++ program.

Once in a whole, a test causes our program to crash, often bringing up a VisualStudio dialog offering me to JustInTime debug the crash. The dialog stops the buildserver from progressing. Instead of the build marked as failed, it just hangs. I've turned off the Just In Time debugging feature in VisualStudio, but when it's turned off, you still get a message "Couldn't JustinTime Debug this, you can turn it on in the options".

Does anybody know of a way to ensure that any unhandled exception in a program does not result in any modal dialog?

5条回答
\"骚年 ilove
2楼-- · 2019-01-30 20:15

In the Window for the question

Do you want to Debug using the selected debugger?

Click YES (new window opens) > OPTIONS (top row menu) > DEBUG

Then in the New window remove the TICK which shows ENABLE JUST IN TIME DEBUGGER. After disabling the JUST IN TIME debugger close the window or click OK Your problem will be solved. I've tried this and got rid of the JUST IN TIME POP UP messages.

查看更多
仙女界的扛把子
3楼-- · 2019-01-30 20:15

Best Solution for this problem is so simple 2 steps to make it done open cmd prompt type : regedit go to path-->HKEY_LOCAL_MACHINE-->SOFTWARE-->Microsoft-->Windows NT-->CurrentVersion-->AeDebug You can find now the file : Debugger right click , Modify copy and paste this text inside it:

drwtsn32 -p %ld -e %ld -g

click ok and voila :)

查看更多
时光不老,我们不散
4楼-- · 2019-01-30 20:16

This MSDN article explains how to disable Just-In-Time debugging on a Windows server. I've included the relevant portion of the article below:

After Visual Studio is installed on a server, the default behavior when an unhandled exception occurs is to show an Exception dialog that requires user intervention to either start Just-In-Time debugging or ignore the exception. This may be undesirable for unattended operation. To configure the server to no longer show a dialog when an unhandled exception occurs (the default behavior prior to installing Visual Studio), use the registry editor to delete the following registry keys:

  • HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\AeDebug\Debugger

  • HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\.NETFramework\DbgManagedDebugger

On a 64-bit operating system also delete the following registry keys:

  • HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\Microsoft\Windows NT\CurrentVersion\AeDebug\Debugger

  • HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\Microsoft\.NETFramework\DbgManagedDebugger

查看更多
Melony?
5楼-- · 2019-01-30 20:29

Delete (or rename) c:\windows\system32\vsjitdebugger.exe.

I tried deleting the registry keys, and I tried unchecking all the boxes in the Visual Studio options, but neither worked.

To be clear, my situation wasn't a C++ one. I was using Micro Focus COBOL for Visual Studio 2010, and by using the registry and VS options suggestions I managed to get rid of the "Want to debug?" dialog, but that resulted in a different dialog to hold up my automated process:

Visual Studio Just-In-Time Debugger

An unhandled exception ('COBOL runtime: Fault detected') occurred in CASDBC.exe [3564]. Just-In-Time debugging this exception failed with the following error: No installed debugger has Just-In-Time debugging enabled. In Visual Studio, Just-In-Time debugging can be enabled from Tools/Options/Debugging/Just-In-Time.

Check the documentation index for 'Just-in-time debugging, errors' for more information.

OK

查看更多
乱世女痞
6楼-- · 2019-01-30 20:33

In my case , on win2012 server, I tried:

  • removing registry keys
  • deleting the exe for the jit debugger from c:\windows\system32

and it still came up!

I rebooted, etc. Was making my web site in IIS stall until dialog was acknowledged!

Final solution, which did work: In control panel, in Programs: Uninstalled "Microsoft Visual Studion 2010 Shell (Isolated)" Uninstalled that, and problem solved.

(Whether SQL Management Studio still works.... I do not know!)

查看更多
登录 后发表回答