2009-07-03 Cary Coutant <ccoutant@google.com>
[platform/upstream/binutils.git] / bfd / dwarf2.c
index 40b83b7..e88a6af 100644 (file)
@@ -432,9 +432,9 @@ read_section (bfd *           abfd,
          return FALSE;
        }
 
+      *section_size = msec->rawsize ? msec->rawsize : msec->size;
       if (syms)
        {
-         *section_size = msec->size;
          *section_buffer
              = bfd_simple_get_relocated_section_contents (abfd, msec, NULL, syms);
          if (! *section_buffer)
@@ -442,7 +442,6 @@ read_section (bfd *           abfd,
        }
       else
        {
-         *section_size = msec->rawsize ? msec->rawsize : msec->size;
          *section_buffer = bfd_malloc (*section_size);
          if (! *section_buffer)
            return FALSE;
@@ -1406,6 +1405,10 @@ decode_line_info (struct comp_unit *unit, struct dwarf2_debug *stash)
                  line_ptr += bytes_read;
                  table->num_files++;
                  break;
+               case DW_LNE_set_discriminator:
+                 (void) read_unsigned_leb128 (abfd, line_ptr, &bytes_read);
+                 line_ptr += bytes_read;
+                 break;
                default:
                  (*_bfd_error_handler) (_("Dwarf Error: mangled line number section."));
                  bfd_set_error (bfd_error_bad_value);