ERROR_DBG_EXCEPTION_HANDLED - 766 (0x2FE)
Debugger handled exception.
Updated: Feb 21, 2026
Technical Meaning
The ERROR_DBG_EXCEPTION_HANDLED error code indicates that a debugger has intercepted and handled an exception. This typically occurs when the operating system encounters an unhandled exception, but the debugger is able to process it.
Error Details
- Error Name: ERROR_DBG_EXCEPTION_HANDLED
- Numeric Code: 766 (0x2FE)
- Short Description: Debugger handled exception.
This error code is often used in kernel-mode debugging scenarios where a debugger is attached to the system and intercepts an exception before it can be processed by the operating system. The debugger then handles the exception, potentially allowing for more detailed analysis or correction of the issue.
Usage Context
The ERROR_DBG_EXCEPTION_HANDLED error code is most commonly encountered in kernel debugging sessions where a debugger such as WinDbg is attached to the system. It can also be observed when using tools like ntsd or other kernel-mode debuggers that are capable of handling exceptions.
Developer Interpretation
When this error code is returned, it indicates that an exception has been handled by a debugger rather than being processed by the operating system. This can occur in various scenarios, such as:
- A driver or application has generated an unhandled exception.
- The system is configured to use a debugger for handling exceptions.
Developers should be aware of this behavior when writing code that interacts with kernel-mode components or uses debugging tools. Understanding the implications of this error can help in diagnosing and resolving issues related to exception handling.
Related Errors
- ERROR_UNHANDLED_EXCEPTION: This error is typically returned by the operating system when an unhandled exception occurs, but no debugger is attached.
- STATUS_DEBUGGER_ATTACHED: Indicates that a debugger has been attached to the system, which can lead to
ERROR_DBG_EXCEPTION_HANDLEDbeing generated if an exception is encountered.
FAQ
Q: What does ERROR_DBG_EXCEPTION_HANDLED mean?
A: It indicates that a debugger has intercepted and handled an exception. This typically occurs in kernel debugging sessions where a debugger is attached to the system.
Q: How can I handle this error in my code?
A: Since this error is generated by the operating system, it cannot be directly handled within user-mode applications. However, understanding its implications can help in diagnosing issues related to exception handling and kernel debugging.
Summary
The ERROR_DBG_EXCEPTION_HANDLED error code is a specific technical indicator used in Windows environments where a debugger has intercepted an unhandled exception. Developers should be aware of this behavior when working with kernel-mode components or using debugging tools, as it can provide valuable insights into the state and operation of the system.