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]

Re: [PATCH] Display full file path in MI style disassembly listing


>>>>> "Andrew" == Andrew Burgess <aburgess@broadcom.com> writes:

Andrew> +	  char *filename;

I think this could be const.

Andrew> +
Andrew> +	  filename = s->fullname;
Andrew> +	  if (filename == NULL)
Andrew> +	    {
Andrew> +	      filename = symtab_to_fullname (s);
Andrew> +	      if (filename == NULL)
Andrew> +		filename = s->filename;
Andrew> +	    }
Andrew> +
Andrew>  	  ui_out_field_int (uiout, "line", line);
Andrew>  	  ui_out_text (uiout, "\tin ");
Andrew> -	  ui_out_field_string (uiout, "file", s->filename);
Andrew> +	  ui_out_field_string (uiout, "file", filename);
Andrew>  	  ui_out_text (uiout, "\n");

It isn't obvious to me that this only applies to the MI case.
Can you explain that?

Tom


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