mirror of
https://github.com/espressif/binutils-gdb.git
synced 2025-08-05 21:50:21 +08:00
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.
This commit is contained in:
@ -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))
|
||||
{
|
||||
|
Reference in New Issue
Block a user