This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [patch] Fix false warning: Shared library is missing debugging information.
- From: Jan Kratochvil <jan dot kratochvil at redhat dot com>
- To: Tristan Gingold <gingold at adacore dot com>, Pedro Alves <pedro at codesourcery dot com>
- Cc: gdb-patches at sourceware dot org
- Date: Mon, 11 Jan 2010 17:07:20 +0100
- Subject: Re: [patch] Fix false warning: Shared library is missing debugging information.
On Mon, 11 Jan 2010 16:22:06 +0100, Tristan Gingold wrote:
> I think you should use !objfile_has_symbols (so->objfile) instead.
OK, missed that function, thanks.
> It is somewhat wrong to check objfile->separate_debug_objfile without
> checking the whole chain, because the chain has no particular order.
When thinking more about it it is probably more important than I thought. One
can have one of the .o files stripped while not the other ones.
On Mon, 11 Jan 2010 16:23:46 +0100, Pedro Alves wrote:
> separate_debug_objfile is now a list, so shouldn't you now look
> over them all (main and all seperate objfiles) for symbols?
yes...
No regressions on {x86_64,x86_64-m32,i686}-fedora12-linux-gnu.
Thanks,
Jan
2010-01-11 Jan Kratochvil <jan.kratochvil@redhat.com>
Tristan Gingold <gingold@adacore.com>
* solib.c (info_sharedlibrary_command): Replace
objfile_has_partial_symbols and objfile_has_full_symbols calls by
objfile_has_symbols.
--- a/gdb/solib.c
+++ b/gdb/solib.c
@@ -863,8 +863,7 @@ info_sharedlibrary_command (char *pattern, int from_tty)
if (! ui_out_is_mi_like_p (interp_ui_out (top_level_interpreter ()))
&& so->symbols_loaded
- && !objfile_has_partial_symbols (so->objfile)
- && !objfile_has_full_symbols (so->objfile))
+ && !objfile_has_symbols (so->objfile))
{
so_missing_debug_info = 1;
ui_out_field_string (uiout, "syms-read", "Yes (*)");