This is the mail archive of the gdb-patches@sources.redhat.com 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: [RFA] dwarf2read.c: complain() -> complaint()


On Dec 10, 11:13am, Andrew Cagney wrote:

> Definitly fine with the theory.  Two reservations (really just one).
> 
> - how is the result with -Wformat?  The reason behind switching from 
> complain() to complaint was to get the parameters checked and hence find 
> some nasty address printing bugs.

No warnings.  (I was looking for this too when I eyeballed the resulting
patch.)

> - I suspect it will need a visual audit to check for any cases of:
> 	"%08lx", (long) core_addr_variable

Yes, I agree.  At the moment my script is only smart enough to handle
the cases that occur in dwarf2read.c.  An excerpt:

		# yes, this is naive, but it's all we need for dwarf2read.c...
		$formals .= 'const char *' if $1 eq 's';
		$formals .= 'long'         if $1 eq 'l';
		$formals .= 'int'          if $1 eq 'd';
		$formals .= 'int'          if $1 eq 'x';

I'll augment the script as I go...  In some cases, hand edits may be
necessary.

Kevin


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