diff options
author | Jan Kratochvil <jan.kratochvil@redhat.com> | 2013-01-13 18:53:51 +0000 |
---|---|---|
committer | Jan Kratochvil <jan.kratochvil@redhat.com> | 2013-01-13 18:53:51 +0000 |
commit | 57b3c00c27e8492b2f8342b38e2301e710e5fabf (patch) | |
tree | b06e9d2e1ac7b974ceb38849bdfa57baf994c880 | |
parent | f0a4b570b43765effcf5b4a1b12c47b9aab1b16f (diff) | |
download | gdb-57b3c00c27e8492b2f8342b38e2301e710e5fabf.zip gdb-57b3c00c27e8492b2f8342b38e2301e710e5fabf.tar.gz gdb-57b3c00c27e8492b2f8342b38e2301e710e5fabf.tar.bz2 |
gdb/
* source.c (symtab_to_fullname): Do not prepend DIRNAME for
non-existing files if FILENAME is already absolute.
-rw-r--r-- | gdb/ChangeLog | 3 | ||||
-rw-r--r-- | gdb/source.c | 2 |
2 files changed, 4 insertions, 1 deletions
diff --git a/gdb/ChangeLog b/gdb/ChangeLog index 5495385..e4c5132 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -3,6 +3,9 @@ * source.c (symtab_to_fullname): Apply rewrite_source_path also for non-existing files. + * source.c (symtab_to_fullname): Do not prepend DIRNAME for + non-existing files if FILENAME is already absolute. + 2013-01-11 Jan Kratochvil <jan.kratochvil@redhat.com> * macrocmd.c (macro_inform_no_debuginfo): Use puts_filtered instead of diff --git a/gdb/source.c b/gdb/source.c index ca6b4f3..54d5693 100644 --- a/gdb/source.c +++ b/gdb/source.c @@ -1102,7 +1102,7 @@ symtab_to_fullname (struct symtab *s) /* rewrite_source_path would be applied by find_and_open_source, we should report the pathname where GDB tried to find the file. */ - if (s->dirname == NULL) + if (s->dirname == NULL || IS_ABSOLUTE_PATH (s->filename)) fullname = xstrdup (s->filename); else fullname = concat (s->dirname, SLASH_STRING, s->filename, NULL); |