sx, sxe, sxd (Set Exceptions)

Syntax

sx [[e | d]] [[eventcode | exceptnum]]

Control the behavior of the debugger when exceptions occur (NTSD only).

The sx command causes the debugger to display its break status for all events, including exceptions.

Followed by one of the two-letter event codes listed below or by an exception number, the sx command causes the debugger to print its break status for the given event. Non-exception events are identified by a two-letter combination:

Event code Meaning
av Access Violation
cc ctrl+c
ct Create Thread
et Exit Thread
ep Exit Process
ld Load DLL

The sx command also can be used to set the debugger's behavior on an event. The sxe command enables the break status for an exception; the sxd command disables the break status of an exception.

On a break on an event, only the g command (not t or p) is allowed to continue execution.

On a first-time break to an exception, special versions of the g command can be used: gh treats the exception as handled, and gn treats the exception as unhandled. A normal g command uses the default disposition.

Second time exceptions always break into the debugger.