summaryrefslogtreecommitdiff
path: root/gdb/exec.c
diff options
context:
space:
mode:
authorTom Tromey <tom@tromey.com>2017-08-03 16:34:56 -0600
committerTom Tromey <tom@tromey.com>2017-08-22 09:30:11 -0600
commit4971c9a74b47103582834e46d0185390379e60b3 (patch)
tree222a7707d371fc4eda57210839ae91c900132960 /gdb/exec.c
parente3e41d588adbe26a6ca54338dd4915382d981a3e (diff)
downloadbinutils-gdb-4971c9a74b47103582834e46d0185390379e60b3.tar.gz
Change gdb_realpath_keepfile to return a unique_xmalloc_ptr
This changes gdb_realpath_keepfile to return a unique_xmalloc_ptr, and fixes up the callers. ChangeLog 2017-08-22 Tom Tromey <tom@tromey.com> * utils.c (gdb_realpath_keepfile): Return a gdb::unique_xmalloc_ptr. * exec.c (exec_file_attach): Update. * utils.h (gdb_realpath_keepfile): Return a gdb::unique_xmalloc_ptr.
Diffstat (limited to 'gdb/exec.c')
-rw-r--r--gdb/exec.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/gdb/exec.c b/gdb/exec.c
index 6980b07f69a..45bc1339195 100644
--- a/gdb/exec.c
+++ b/gdb/exec.c
@@ -352,7 +352,7 @@ exec_file_attach (const char *filename, int from_tty)
if (load_via_target)
exec_filename = xstrdup (bfd_get_filename (exec_bfd));
else
- exec_filename = gdb_realpath_keepfile (scratch_pathname);
+ exec_filename = gdb_realpath_keepfile (scratch_pathname).release ();
if (!bfd_check_format_matches (exec_bfd, bfd_object, &matching))
{