summaryrefslogtreecommitdiff
path: root/bfd/aoutx.h
diff options
context:
space:
mode:
authorTom Tromey <tromey@redhat.com>2009-07-02 17:08:51 +0000
committerTom Tromey <tromey@redhat.com>2009-07-02 17:08:51 +0000
commit0db2e5cb48751264be244557133c481fae90a41c (patch)
treee82772b7712382b0c6b642522cdae54db955485a /bfd/aoutx.h
parent4e8d0a7de9986d1c8f5350b59010924ada0670e3 (diff)
downloadbinutils-redhat-0db2e5cb48751264be244557133c481fae90a41c.tar.gz
* aoutx.h (aout_get_external_symbols): Declare 'amt' locally.
* bfdwin.c (bfd_free_window): Cast to unsigned long.
Diffstat (limited to 'bfd/aoutx.h')
-rw-r--r--bfd/aoutx.h20
1 files changed, 11 insertions, 9 deletions
diff --git a/bfd/aoutx.h b/bfd/aoutx.h
index fccfdeb0d1..480761de62 100644
--- a/bfd/aoutx.h
+++ b/bfd/aoutx.h
@@ -1,6 +1,6 @@
/* BFD semi-generic back-end for a.out binaries.
Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
- 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007
+ 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2009
Free Software Foundation, Inc.
Written by Cygnus Support.
@@ -1294,7 +1294,6 @@ aout_get_external_symbols (bfd *abfd)
{
bfd_size_type count;
struct external_nlist *syms;
- bfd_size_type amt;
count = exec_hdr (abfd)->a_syms / EXTERNAL_NLIST_SIZE;
if (count == 0)
@@ -1314,13 +1313,16 @@ aout_get_external_symbols (bfd *abfd)
if (syms == NULL)
return FALSE;
- amt = exec_hdr (abfd)->a_syms;
- if (bfd_seek (abfd, obj_sym_filepos (abfd), SEEK_SET) != 0
- || bfd_bread (syms, amt, abfd) != amt)
- {
- free (syms);
- return FALSE;
- }
+ {
+ bfd_size_type amt;
+ amt = exec_hdr (abfd)->a_syms;
+ if (bfd_seek (abfd, obj_sym_filepos (abfd), SEEK_SET) != 0
+ || bfd_bread (syms, amt, abfd) != amt)
+ {
+ free (syms);
+ return FALSE;
+ }
+ }
#endif
obj_aout_external_syms (abfd) = syms;