diff options
Diffstat (limited to 'gdb/dwarf2read.c')
-rw-r--r-- | gdb/dwarf2read.c | 31 |
1 files changed, 5 insertions, 26 deletions
diff --git a/gdb/dwarf2read.c b/gdb/dwarf2read.c index cef20e2..5f958a9 100644 --- a/gdb/dwarf2read.c +++ b/gdb/dwarf2read.c @@ -3020,8 +3020,7 @@ dw2_forget_cached_source_info (struct objfile *objfile) static int dw2_map_expand_apply (struct objfile *objfile, struct dwarf2_per_cu_data *per_cu, - const char *name, - const char *full_path, const char *real_path, + const char *name, const char *real_path, int (*callback) (struct symtab *, void *), void *data) { @@ -3035,7 +3034,7 @@ dw2_map_expand_apply (struct objfile *objfile, all of them. */ dw2_instantiate_symtab (per_cu); - return iterate_over_some_symtabs (name, full_path, real_path, callback, data, + return iterate_over_some_symtabs (name, real_path, callback, data, objfile->symtabs, last_made); } @@ -3043,7 +3042,7 @@ dw2_map_expand_apply (struct objfile *objfile, static int dw2_map_symtabs_matching_filename (struct objfile *objfile, const char *name, - const char *full_path, const char *real_path, + const char *real_path, int (*callback) (struct symtab *, void *), void *data) { @@ -3077,8 +3076,7 @@ dw2_map_symtabs_matching_filename (struct objfile *objfile, const char *name, if (FILENAME_CMP (name, this_name) == 0 || (!is_abs && compare_filenames_for_search (this_name, name))) { - if (dw2_map_expand_apply (objfile, per_cu, - name, full_path, real_path, + if (dw2_map_expand_apply (objfile, per_cu, name, real_path, callback, data)) return 1; } @@ -3089,24 +3087,6 @@ dw2_map_symtabs_matching_filename (struct objfile *objfile, const char *name, && FILENAME_CMP (lbasename (this_name), name_basename) != 0) continue; - if (full_path != NULL) - { - const char *this_real_name = dw2_get_real_path (objfile, - file_data, j); - - if (this_real_name != NULL - && (FILENAME_CMP (full_path, this_real_name) == 0 - || (!is_abs - && compare_filenames_for_search (this_real_name, - name)))) - { - if (dw2_map_expand_apply (objfile, per_cu, - name, full_path, real_path, - callback, data)) - return 1; - } - } - if (real_path != NULL) { const char *this_real_name = dw2_get_real_path (objfile, @@ -3118,8 +3098,7 @@ dw2_map_symtabs_matching_filename (struct objfile *objfile, const char *name, && compare_filenames_for_search (this_real_name, name)))) { - if (dw2_map_expand_apply (objfile, per_cu, - name, full_path, real_path, + if (dw2_map_expand_apply (objfile, per_cu, name, real_path, callback, data)) return 1; } |