daily update
[deliverable/binutils-gdb.git] / bfd / syms.c
index 86ea521909925a9b03aa7776a05dfcd65ee1a735..6b615a2b5f4bec35c901e2f59cd423972f6b4b49 100644 (file)
@@ -1,6 +1,6 @@
 /* Generic symbol-table support for the BFD library.
    Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
-   2000, 2001, 2002, 2003
+   2000, 2001, 2002, 2003, 2004
    Free Software Foundation, Inc.
    Written by Cygnus Support.
 
@@ -133,9 +133,9 @@ SUBSECTION
 |      nm foo
 |      00012345 A dummy_symbol
 
-       Many formats cannot represent arbitary symbol information; for
+       Many formats cannot represent arbitrary symbol information; for
        instance, the <<a.out>> object format does not allow an
-       arbitary number of sections. A symbol pointing to a section
+       arbitrary number of sections. A symbol pointing to a section
        which is not one  of <<.text>>, <<.data>> or <<.bss>> cannot
        be described.
 
@@ -181,7 +181,7 @@ SUBSECTION
 CODE_FRAGMENT
 
 .
-.typedef struct symbol_cache_entry
+.typedef struct bfd_symbol
 .{
 .  {* A pointer to the BFD which owns the symbol. This information
 .     is necessary so that a back end can work out what additional
@@ -222,7 +222,7 @@ CODE_FRAGMENT
 .     <<BSF_LOCAL>>, <<BSF_FORT_COMM>>,  <<BSF_UNDEFINED>> or
 .     <<BSF_GLOBAL>>.  *}
 .
-.  {* The symbol is a debugging record. The value has an arbitary
+.  {* The symbol is a debugging record. The value has an arbitrary
 .     meaning, unless BSF_DEBUGGING_RELOC is also set.  *}
 .#define BSF_DEBUGGING 0x08
 .
@@ -934,8 +934,12 @@ _bfd_stab_section_find_nearest_line (bfd *abfd,
          return TRUE;
        }
 
-      stabsize = info->stabsec->_raw_size;
-      strsize = info->strsec->_raw_size;
+      stabsize = (info->stabsec->rawsize
+                 ? info->stabsec->rawsize
+                 : info->stabsec->size);
+      strsize = (info->strsec->rawsize
+                ? info->strsec->rawsize
+                : info->strsec->size);
     }
   else
     {
@@ -965,8 +969,12 @@ _bfd_stab_section_find_nearest_line (bfd *abfd,
          return TRUE;
        }
 
-      stabsize = info->stabsec->_raw_size;
-      strsize = info->strsec->_raw_size;
+      stabsize = (info->stabsec->rawsize
+                 ? info->stabsec->rawsize
+                 : info->stabsec->size);
+      strsize = (info->strsec->rawsize
+                ? info->strsec->rawsize
+                : info->strsec->size);
 
       info->stabs = bfd_alloc (abfd, stabsize);
       info->strs = bfd_alloc (abfd, strsize);
@@ -974,9 +982,9 @@ _bfd_stab_section_find_nearest_line (bfd *abfd,
        return FALSE;
 
       if (! bfd_get_section_contents (abfd, info->stabsec, info->stabs,
-                                     (bfd_vma) 0, stabsize)
+                                     0, stabsize)
          || ! bfd_get_section_contents (abfd, info->strsec, info->strs,
-                                        (bfd_vma) 0, strsize))
+                                        0, strsize))
        return FALSE;
 
       /* If this is a relocatable object file, we have to relocate
@@ -1222,7 +1230,7 @@ _bfd_stab_section_find_nearest_line (bfd *abfd,
       long low, high;
       long mid = -1;
 
-      /* Cache non-existant or invalid.  Do binary search on
+      /* Cache non-existent or invalid.  Do binary search on
          indextable.  */
       indexentry = NULL;
 
This page took 0.026365 seconds and 4 git commands to generate.