This is the mail archive of the gdb-cvs@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

src/gdb ChangeLog elfread.c minsyms.c printcmd ...


CVSROOT:	/cvs/src
Module name:	src
Changes by:	brobecke@sourceware.org	2012-09-11 21:26:16

Modified files:
	gdb            : ChangeLog elfread.c minsyms.c printcmd.c 
	                 symtab.h 

Log message:
	Name of symbol missing when printing global variable's address
	
	The build_address_symbolic funnction filters out data symbols if
	their size is set to zero.  But the problem is that the COFF symbol
	table (for instance) does not provide any size information, leaving
	the size to its default value of zero, thus always triggering
	the filter.
	
	This shows up when trying to print the address of a global variable
	when debugging a Windows executable, for instance.
	
	gdb/ChangeLog:
	
	* symtab.h (struct minimal_symbol) [has_size]: New field.
	(MSYMBOL_SIZE): Adjust to forbid macro from being used as lvalue.
	(SET_MSYMBOL_SIZE, MSYMBOL_HAS_SIZE): New macros.
	* printcmd.c (build_address_symbolic): Only filter out zero-sized
	minimal symbols if the symbol's size is actually known.
	* minsyms.c (prim_record_minimal_symbol_full): Adjust setting
	of msymbol's size field.  Add comment.
	* elfread.c (elf_symtab_read, elf_rel_plt_read): Use
	SET_MSYMBOL_SIZE to set the minimal symbol size.

Patches:
http://sourceware.org/cgi-bin/cvsweb.cgi/src/gdb/ChangeLog.diff?cvsroot=src&r1=1.14650&r2=1.14651
http://sourceware.org/cgi-bin/cvsweb.cgi/src/gdb/elfread.c.diff?cvsroot=src&r1=1.138&r2=1.139
http://sourceware.org/cgi-bin/cvsweb.cgi/src/gdb/minsyms.c.diff?cvsroot=src&r1=1.92&r2=1.93
http://sourceware.org/cgi-bin/cvsweb.cgi/src/gdb/printcmd.c.diff?cvsroot=src&r1=1.210&r2=1.211
http://sourceware.org/cgi-bin/cvsweb.cgi/src/gdb/symtab.h.diff?cvsroot=src&r1=1.210&r2=1.211


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]