* aoutx.h (NAME(aout,find_nearest_line)): Make room for the
authorIan Lance Taylor <ian@airs.com>
Tue, 28 May 1996 15:48:13 +0000 (15:48 +0000)
committerIan Lance Taylor <ian@airs.com>
Tue, 28 May 1996 15:48:13 +0000 (15:48 +0000)
potential leading underscore in the allocated buffer.

bfd/ChangeLog
bfd/aoutx.h

index 298a524bfdd17690daa5b2b898eb50f90cffd6d3..733fcd24de7326eb21cdfc24dcd620d108712508 100644 (file)
@@ -1,3 +1,8 @@
+Tue May 28 11:42:08 1996  Ian Lance Taylor  <ian@cygnus.com>
+
+       * aoutx.h (NAME(aout,find_nearest_line)): Make room for the
+       potential leading underscore in the allocated buffer.
+
 Fri May 24 14:28:38 1996  Michael Meissner  <meissner@tiktok.cygnus.com>
 
        * elf32-ppc.c (ppc_elf_add_symbol_hook): Do not put small common
index fd550e0e874bbae4b79ade6884f240c76bff559e..8bba2a2d537ffe9de94376108c2c4477192ae003 100644 (file)
@@ -1496,6 +1496,22 @@ translate_from_native_sym_flags (abfd, cache_ptr)
 
 #endif /* 0 */
 
+       switch (cache_ptr->type & N_TYPE)
+         {
+         case N_SETA:
+           cache_ptr->symbol.section = bfd_abs_section_ptr;
+           break;
+         case N_SETT:
+           cache_ptr->symbol.section = obj_textsec (abfd);
+           break;
+         case N_SETD:
+           cache_ptr->symbol.section = obj_datasec (abfd);
+           break;
+         case N_SETB:
+           cache_ptr->symbol.section = obj_bsssec (abfd);
+           break;
+         }
+
        cache_ptr->symbol.flags |= BSF_CONSTRUCTOR;
       }
       break;
@@ -2732,7 +2748,7 @@ NAME(aout,find_nearest_line)
     adata (abfd).line_buf = buf = NULL;
   else
     {
-      buf = (char *) bfd_malloc (filelen + funclen + 2);
+      buf = (char *) bfd_malloc (filelen + funclen + 3);
       adata (abfd).line_buf = buf;
       if (buf == NULL)
        return false;