Jump to content

DBG_N_ModuleFree

From EDM2
Revision as of 23:54, 4 March 2020 by Martini (talk | contribs) (Created page with "Debug Notification -16 - Module Free Notification This notification returns: * Cmd= DBG_N_ModuleFree * Value= MTE (Module Table Entry) handle of freed module * Addr= 0 ...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

Debug Notification -16 - Module Free Notification

This notification returns:

  • Cmd= DBG_N_ModuleFree
  • Value= MTE (Module Table Entry) handle of freed module
  • Addr= 0

A module has just been freed. This occurs either at program termination, or during execution of the DosFreeModule.

The newly attached module's handle is returned via Value. You can use this handle with DosQueryModuleName, or with the DosDebug DBG_C_NumToAddr command, for symbolic debugging. A debugger should save these handles for future reference.

There may be many modules freed at one time, but DosDebug is only able to communicate the freeing of a single module during any one notification. In this case, the additional notifications of freed modules become pending. The debugger should issue repeated DBG_C_Stop commands to be notified of these additional module freeing operations, until DBG_N_Error is returned from the DBG_C_Stop command. If the DBG_C_Go or DBG_C_SStep commands are issued instead of the DBG_C_Stop command, the pending notifications will be returned immediately, until there are no further notifications.