Return unique_xmalloc_ptr from gdbscm_safe_eval_string
authorTom Tromey <tom@tromey.com>
Sun, 27 May 2018 05:26:39 +0000 (23:26 -0600)
committerTom Tromey <tom@tromey.com>
Tue, 17 Jul 2018 19:21:47 +0000 (13:21 -0600)
commita1a31cb8dce7d1bfa7878dc08c28af330ef2ed69
tree7819771634fdc0ad4ef245800c3b354abf6382e4
parent15bf30027bcb167833a0ca2c619c03f177ef1ba4
Return unique_xmalloc_ptr from gdbscm_safe_eval_string

This changes gdbscm_safe_eval_string to return a unique_xmalloc_ptr.
This allows for the removal of some cleanups.  It also fixes a
potential latent memory leak in gdbscm_set_backtrace.

gdb/ChangeLog
2018-07-17  Tom Tromey  <tom@tromey.com>

* guile/guile.c (gdbscm_eval_from_control_command): Update.
* guile/guile-internal.h (gdbscm_safe_eval_string): Update.
* guile/scm-objfile.c (gdbscm_execute_objfile_script): Update.
* guile/scm-safe-call.c (gdbscm_safe_eval_string): Return
unique_xmalloc_ptr.
gdb/ChangeLog
gdb/guile/guile-internal.h
gdb/guile/guile.c
gdb/guile/scm-objfile.c
gdb/guile/scm-safe-call.c