aboutsummaryrefslogtreecommitdiff
path: root/gdb/symfile.c
diff options
context:
space:
mode:
authorTom Tromey <tom@tromey.com>2018-09-06 14:49:39 -0600
committerTom Tromey <tom@tromey.com>2018-12-28 12:49:52 -0700
commit47fd17cdc14a0d295a2cbdc02eff144e3fb4e900 (patch)
tree784f863deda25b727721b59b62de1dece685f563 /gdb/symfile.c
parentd47032b7ca85852acb1d2bc645f477ffee4373fc (diff)
downloadgdb-47fd17cdc14a0d295a2cbdc02eff144e3fb4e900.zip
gdb-47fd17cdc14a0d295a2cbdc02eff144e3fb4e900.tar.gz
gdb-47fd17cdc14a0d295a2cbdc02eff144e3fb4e900.tar.bz2
Style the "Reading symbols" message
The "Reading symbols" message does not use ui-out (perhaps it should?), so this styles it using the low-level API. gdb/ChangeLog 2018-12-28 Tom Tromey <tom@tromey.com> * symfile.c (symbol_file_add_with_addrs): Style file name. gdb/testsuite/ChangeLog 2018-12-28 Tom Tromey <tom@tromey.com> * gdb.base/style.exp: Add test for styling of "Reading symbols" message.
Diffstat (limited to 'gdb/symfile.c')
-rw-r--r--gdb/symfile.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/gdb/symfile.c b/gdb/symfile.c
index 991b71f..ce1cc9e 100644
--- a/gdb/symfile.c
+++ b/gdb/symfile.c
@@ -58,6 +58,7 @@
#include "cli/cli-utils.h"
#include "common/byte-vector.h"
#include "selftest.h"
+#include "cli/cli-style.h"
#include <sys/types.h>
#include <fcntl.h>
@@ -1110,7 +1111,11 @@ symbol_file_add_with_addrs (bfd *abfd, const char *name,
if (deprecated_pre_add_symbol_hook)
deprecated_pre_add_symbol_hook (name);
else
- printf_filtered (_("Reading symbols from %s...\n"), name);
+ {
+ puts_filtered (_("Reading symbols from "));
+ fputs_styled (name, file_name_style.style (), gdb_stdout);
+ puts_filtered ("...\n");
+ }
}
syms_from_objfile (objfile, addrs, add_flags);