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]

[RFA] tui-winsource.c, initialize sal.pspace


Does this strike anybody as likely to be correct?

2011-03-02  Michael Snyder  <msnyder@vmware.com>

	* tui/tui-winsource.c (tui_update_source_window_as_is): Initialize
	sal.pspace before calling set_current_source_symtab_and_line.

Index: tui/tui-winsource.c
===================================================================
RCS file: /cvs/src/src/gdb/tui/tui-winsource.c,v
retrieving revision 1.40
diff -u -p -u -p -r1.40 tui-winsource.c
--- tui/tui-winsource.c	27 Feb 2011 16:25:38 -0000	1.40
+++ tui/tui-winsource.c	2 Mar 2011 21:12:02 -0000
@@ -114,9 +114,11 @@ tui_update_source_window_as_is (struct t
 	{
 	  struct symtab_and_line sal;
 	  
+	  init_sal (&sal);
 	  sal.line = line_or_addr.u.line_no +
 	    (win_info->generic.content_size - 2);
 	  sal.symtab = s;
+	  sal.pspace = current_program_space;
 	  set_current_source_symtab_and_line (&sal);
 	  /* If the focus was in the asm win, put it in the src win if
 	     we don't have a split layout.  */

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