same effect the instruction would have had if we had executed it
at its original address. We use this in step n3.
- - gdbarch_displaced_step_free_closure provides cleanup.
-
The gdbarch_displaced_step_copy_insn and
gdbarch_displaced_step_fixup functions must be written so that
copying an instruction with gdbarch_displaced_step_copy_insn,
displaced step operation on it. See displaced_step_prepare and
displaced_step_fixup for details. */
+/* Default destructor for displaced_step_closure. */
+
+displaced_step_closure::~displaced_step_closure () = default;
+
/* Per-inferior displaced stepping state. */
struct displaced_step_inferior_state
{
/* Indicate that there is no cleanup pending. */
displaced->step_ptid = null_ptid;
- xfree (displaced->step_closure);
+ delete displaced->step_closure;
displaced->step_closure = NULL;
}