summaryrefslogtreecommitdiff
path: root/gdb/nto-tdep.c
diff options
context:
space:
mode:
authorPedro Alves <palves@redhat.com>2011-03-09 12:48:56 +0000
committerPedro Alves <palves@redhat.com>2011-03-09 12:48:56 +0000
commit9f37bbcca8004e1ac5be674446c51b50b36dc94e (patch)
tree02a5d9a92d9719944c943c4f7160cc3a6d42fc5a /gdb/nto-tdep.c
parentf8de3c55e995e88e61316d7025e4d83927497e18 (diff)
downloadbinutils-gdb-9f37bbcca8004e1ac5be674446c51b50b36dc94e.tar.gz
* cli/cli-cmds.c (shell_escape): Use lbasename.
* coffread.c (coff_start_symtab): Constify parameter. (complete_symtab): Constify `name' parameter. (coff_symtab_read): Constify `filestring' local. (coff_getfilename): Constify return and `result' local. Use lbasename. * fbsd-nat.c (fbsd_make_corefile_notes): Use lbasename. * linux-fork.c (info_checkpoints_command): Use lbasename. * linux-nat.c (linux_nat_make_corefile_notes): Use lbasename. * minsyms.c (lookup_minimal_symbol): Use lbasename. * nto-tdep.c (nto_find_and_open_solib): Use lbasename. * procfs.c (procfs_make_note_section): Use lbasename. * tui/tui-io.c (printable_part): Constity return and parameter. Use lbasename. (print_filename): Constify parameters, and local `s'. (tui_rl_display_match_list): Constify local `temp'.
Diffstat (limited to 'gdb/nto-tdep.c')
-rw-r--r--gdb/nto-tdep.c8
1 files changed, 1 insertions, 7 deletions
diff --git a/gdb/nto-tdep.c b/gdb/nto-tdep.c
index 5858dc26ece..23bbd3122b0 100644
--- a/gdb/nto-tdep.c
+++ b/gdb/nto-tdep.c
@@ -127,13 +127,7 @@ nto_find_and_open_solib (char *solib, unsigned o_flags, char **temp_pathname)
sprintf (buf, PATH_FMT, arch_path, arch_path, arch_path, arch_path,
arch_path);
- /* Don't assume basename() isn't destructive. */
- base = strrchr (solib, '/');
- if (!base)
- base = solib;
- else
- base++; /* Skip over '/'. */
-
+ base = lbasename (solib);
ret = openp (buf, 1, base, o_flags, temp_pathname);
if (ret < 0 && base != solib)
{