This is the mail archive of the gdb-patches@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]

[patch] Comment symbol->symtab NULL [Re: [patch] Fix solib-display.exp crash]


On Tue, 26 Jan 2010 22:24:25 +0100, Daniel Jacobowitz wrote:
> On Wed, Jan 20, 2010 at 12:40:01AM +0100, Jan Kratochvil wrote:
> > The question is whether SYMBOL_SYMTAB (symbol) can be ever NULL at this point.
> > IMO not, it can be NULL only temporarily during reading symbols.
> 
> I think that's right; this patch is fine.  Thanks!

Checked-in:
	http://sourceware.org/ml/gdb-cvs/2010-01/msg00217.html


OK to check-in this comment?


Thanks,
Jan

2010-01-27  Jan Kratochvil  <jan.kratochvil@redhat.com>

	* symtab.h (struct symbol <symtab>): New comment on NULL values.

--- a/gdb/symtab.h
+++ b/gdb/symtab.h
@@ -554,7 +554,8 @@ struct symbol
   struct type *type;
 
   /* The symbol table containing this symbol.  This is the file
-     associated with LINE.  */
+     associated with LINE.  It can be NULL during symbols read-in but it is
+     never NULL during normal operation.  */
   struct symtab *symtab;
 
   /* Domain code.  */


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