public inbox for binutils@sourceware.org
 help / color / mirror / Atom feed
* PATCH: PR ld/2443: Dwarf2 reader doesn't handle file 0 correctly
@ 2006-03-10 20:53 H. J. Lu
  2006-03-11  9:01 ` Nick Clifton
  0 siblings, 1 reply; 2+ messages in thread
From: H. J. Lu @ 2006-03-10 20:53 UTC (permalink / raw)
  To: binutils

According to DWARF 3, 0 means no source file has been specified. We
shouldn't complain about it.


H.J.
---
2006-03-10  H.J. Lu  <hongjiu.lu@intel.com>

	PR ld/2443
	* dwarf2.c (concat_filename): Don't issue an error if file is
	0.

--- bfd/dwarf2.c.bad	2006-03-06 14:23:14.000000000 -0800
+++ bfd/dwarf2.c	2006-03-10 12:48:20.000000000 -0800
@@ -865,8 +865,10 @@ concat_filename (struct line_info_table 
 
   if (file - 1 >= table->num_files)
     {
-      (*_bfd_error_handler)
-	(_("Dwarf Error: mangled line number section (bad file number)."));
+      /* FILE == 0 means unknown.  */
+      if (file)
+	(*_bfd_error_handler)
+	  (_("Dwarf Error: mangled line number section (bad file number)."));
       return strdup ("<unknown>");
     }
 

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: PATCH: PR ld/2443: Dwarf2 reader doesn't handle file 0 correctly
  2006-03-10 20:53 PATCH: PR ld/2443: Dwarf2 reader doesn't handle file 0 correctly H. J. Lu
@ 2006-03-11  9:01 ` Nick Clifton
  0 siblings, 0 replies; 2+ messages in thread
From: Nick Clifton @ 2006-03-11  9:01 UTC (permalink / raw)
  To: H. J. Lu; +Cc: binutils

Hi H. J.

> 2006-03-10  H.J. Lu  <hongjiu.lu@intel.com>
> 
> 	PR ld/2443
> 	* dwarf2.c (concat_filename): Don't issue an error if file is
> 	0.

Approved - please apply.

Cheers
   Nick

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2006-03-11  9:01 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2006-03-10 20:53 PATCH: PR ld/2443: Dwarf2 reader doesn't handle file 0 correctly H. J. Lu
2006-03-11  9:01 ` Nick Clifton

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).