aboutsummaryrefslogtreecommitdiff
path: root/bfd
diff options
context:
space:
mode:
authorTristan Gingold <gingold@adacore.com>2012-01-06 11:43:51 +0000
committerTristan Gingold <gingold@adacore.com>2012-01-06 11:43:51 +0000
commit36f0a48f6c9a1927618d55b4a7df8ddfbfd0fb9d (patch)
tree2e8a9d083dbaded13ffbf30c13bca575cc0b9054 /bfd
parent76d4c1cb5c6d50b4a9b4a2373fe5ced0ce48d642 (diff)
downloadgdb-36f0a48f6c9a1927618d55b4a7df8ddfbfd0fb9d.zip
gdb-36f0a48f6c9a1927618d55b4a7df8ddfbfd0fb9d.tar.gz
gdb-36f0a48f6c9a1927618d55b4a7df8ddfbfd0fb9d.tar.bz2
2012-01-06 Tristan Gingold <gingold@adacore.com>
* bfdio.c (bfd_bread): Use arelt_size macro.
Diffstat (limited to 'bfd')
-rw-r--r--bfd/ChangeLog4
-rw-r--r--bfd/bfdio.c2
2 files changed, 5 insertions, 1 deletions
diff --git a/bfd/ChangeLog b/bfd/ChangeLog
index 3035c22..f9d28f3 100644
--- a/bfd/ChangeLog
+++ b/bfd/ChangeLog
@@ -1,5 +1,9 @@
2012-01-06 Tristan Gingold <gingold@adacore.com>
+ * bfdio.c (bfd_bread): Use arelt_size macro.
+
+2012-01-06 Tristan Gingold <gingold@adacore.com>
+
* config.bfd (i[3-7]86-*-darwin*): Define targ64_selvecs.
2012-01-05 Nick Clifton <nickc@redhat.com>
diff --git a/bfd/bfdio.c b/bfd/bfdio.c
index 841c781..f8c9f3e 100644
--- a/bfd/bfdio.c
+++ b/bfd/bfdio.c
@@ -185,7 +185,7 @@ bfd_bread (void *ptr, bfd_size_type size, bfd *abfd)
this element. */
if (abfd->arelt_data != NULL)
{
- size_t maxbytes = ((struct areltdata *) abfd->arelt_data)->parsed_size;
+ size_t maxbytes = arelt_size (abfd);
if (abfd->where + size > maxbytes)
{
if (abfd->where >= maxbytes)