gdb: make gdbarch_displaced_step_copy_insn return an std::unique_ptr
[deliverable/binutils-gdb.git] / gdb / rs6000-tdep.c
index f61009941da294257a71dd833260d0775f126d4f..e4bbb591f472b99667af81cdcff2f60d346792dd 100644 (file)
@@ -855,7 +855,7 @@ typedef buf_displaced_step_closure ppc_displaced_step_closure;
 
 /* We can't displaced step atomic sequences.  */
 
-static struct displaced_step_closure *
+static std::unique_ptr<displaced_step_closure>
 ppc_displaced_step_copy_insn (struct gdbarch *gdbarch,
                              CORE_ADDR from, CORE_ADDR to,
                              struct regcache *regs)
@@ -894,7 +894,7 @@ ppc_displaced_step_copy_insn (struct gdbarch *gdbarch,
       displaced_step_dump_bytes (gdb_stdlog, buf, len);
     }
 
-  return closure.release ();
+  return closure;
 }
 
 /* Fix up the state of registers and memory after having single-stepped
This page took 0.023163 seconds and 4 git commands to generate.