Jump to content

DBG_C_WriteMemBuf

From EDM2
Revision as of 23:31, 4 March 2020 by Martini (talk | contribs) (Created page with "Debug Command 23 - Write Memory Buffer Command ;Parameters *Pid= Process ID of debuggee *Cmd= DBG_C_WriteMemBuf *Addr= Debuggee address to write to *Buffer= Debugger add...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

Debug Command 23 - Write Memory Buffer Command

Parameters
  • Pid= Process ID of debuggee
  • Cmd= DBG_C_WriteMemBuf
  • Addr= Debuggee address to write to
  • Buffer= Debugger address to copy from
  • Len= Number of bytes to write
Returns

The number of bytes specified by Len is copied from the debugger's Buffer into the debuggee's memory space starting at Addr.

This command is not serialized with respect to the DBG_C_Go command.

In the case of a write to shared read-only memory, the memory is first converted to private, and any set dynamic RAS logging points are removed from that memory, before the write is performed.

Dynamic RAS logging will continue to function in that area, in the context of other processes. The area will continue to be shared by other processes, if any.

In this way, breakpoints may be set in the debuggee without affecting the other modules.

Restrictions

You are unable to write to any memory outside user space.

Both specified memory regions must be currently valid.