diff options
author | Tom Tromey <tom@tromey.com> | 2018-08-29 23:03:09 -0600 |
---|---|---|
committer | Tom Tromey <tom@tromey.com> | 2018-09-13 16:22:34 -0600 |
commit | 803c08d083556154cd4d27368e58b359e9de8b93 (patch) | |
tree | 900369c589d11a5926ca59fe244987389692a526 /gdb/utils.h | |
parent | 5b4cbbe357aaf6462a68e1a15c9532dd3d01e06d (diff) | |
download | fsf-binutils-gdb-803c08d083556154cd4d27368e58b359e9de8b93.zip fsf-binutils-gdb-803c08d083556154cd4d27368e58b359e9de8b93.tar.gz fsf-binutils-gdb-803c08d083556154cd4d27368e58b359e9de8b93.tar.bz2 |
Return std::string from gdb_bfd_errmsg
This changes gdb_bfd_errmsg to return a std::string, removing a
cleanup. This approach may be slightly less efficient than the
previous code, but I don't believe this is very important in this
situation.
gdb/ChangeLog
2018-09-13 Tom Tromey <tom@tromey.com>
* utils.h (gdb_bfd_errmsg): Return std::string.
* exec.c (exec_file_attach): Update.
* compile/compile-object-load.c (compile_object_load): Update.
* utils.c (gdb_bfd_errmsg): Return std::string.
Diffstat (limited to 'gdb/utils.h')
-rw-r--r-- | gdb/utils.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/gdb/utils.h b/gdb/utils.h index 6852399..fa9a590 100644 --- a/gdb/utils.h +++ b/gdb/utils.h @@ -115,7 +115,7 @@ compare_cstrings (const char *str1, const char *str2) MATCHING, if non-NULL, is the corresponding argument to bfd_check_format_matches, and will be freed. */ -extern const char *gdb_bfd_errmsg (bfd_error_type error_tag, char **matching); +extern std::string gdb_bfd_errmsg (bfd_error_type error_tag, char **matching); /* Reset the prompt_for_continue clock. */ void reset_prompt_for_continue_wait_time (void); |