* dwarf_reader.cc (Sized_dwarf_line_info::Sized_dwarf_line_info):
authorCary Coutant <ccoutant@google.com>
Wed, 17 Nov 2010 01:53:22 +0000 (01:53 +0000)
committerCary Coutant <ccoutant@google.com>
Wed, 17 Nov 2010 01:53:22 +0000 (01:53 +0000)
Check for ".zdebug_line".

gold/ChangeLog
gold/dwarf_reader.cc

index 2e3b87feaf53b10994014d7cbd6f455d30c7e588..97e6e2838e66afd0eb34d04dd339b4c2463c1fca 100644 (file)
@@ -1,3 +1,9 @@
+2010-11-16  Cary Coutant  <ccoutant@google.com>
+
+       PR gold/12220
+       * dwarf_reader.cc (Sized_dwarf_line_info::Sized_dwarf_line_info):
+       Check for ".zdebug_line".
+
 2010-11-16  Doug Kwan  <dougkwan@google.com>
            Cary Coutant  <ccoutant@google.com>
 
index c0188fbd435b5bac060a2017f581abba00bc2274..e83e7fb52500ced2ba612906788e33cca6610ede 100644 (file)
@@ -68,16 +68,19 @@ Sized_dwarf_line_info<size, big_endian>::Sized_dwarf_line_info(Object* object,
     directories_(), files_(), current_header_index_(-1)
 {
   unsigned int debug_shndx;
-  for (debug_shndx = 0; debug_shndx < object->shnum(); ++debug_shndx)
-    // FIXME: do this more efficiently: section_name() isn't super-fast
-    if (object->section_name(debug_shndx) == ".debug_line")
-      {
-        section_size_type buffer_size;
-        this->buffer_ = object->section_contents(debug_shndx, &buffer_size,
-                                                false);
-        this->buffer_end_ = this->buffer_ + buffer_size;
-        break;
-      }
+  for (debug_shndx = 1; debug_shndx < object->shnum(); ++debug_shndx)
+    {
+      // FIXME: do this more efficiently: section_name() isn't super-fast
+      std::string name = object->section_name(debug_shndx);
+      if (name == ".debug_line" || name == ".zdebug_line")
+       {
+         section_size_type buffer_size;
+         this->buffer_ = object->section_contents(debug_shndx, &buffer_size,
+                                                  false);
+         this->buffer_end_ = this->buffer_ + buffer_size;
+         break;
+       }
+    }
   if (this->buffer_ == NULL)
     return;
 
This page took 0.030611 seconds and 4 git commands to generate.