This is the mail archive of the
binutils@sourceware.org
mailing list for the binutils project.
[PATCH] bfd, thin archives: remove bogus check
- From: "Jan Beulich" <JBeulich at novell dot com>
- To: <binutils at sourceware dot org>
- Cc: <ccoutant at google dot com>
- Date: Fri, 24 Jul 2009 10:22:15 +0100
- Subject: [PATCH] bfd, thin archives: remove bogus check
Some of the code in get_extended_arelt_filename() was apparently cloned
for the special handling thin archives require, but the range check on
index, which has happened earlier already, doesn't need to be repeated
here (and is confusing to readers like me).
bfd/
2009-07-24 Jan Beulich <jbeulich@novell.com>
* archive.c (get_extended_arelt_filename): Remove redundant
range check on index.
--- 2009-07-24/bfd/archive.c 2009-04-15 08:47:16.000000000 +0200
+++ 2009-07-24/bfd/archive.c 2009-07-24 10:31:48.000000000 +0200
@@ -373,7 +373,7 @@ get_extended_arelt_filename (bfd *arch,
{
file_ptr origin = strtol (endp + 1, NULL, 10);
- if (errno != 0 || index >= bfd_ardata (arch)->extended_names_size)
+ if (errno != 0)
{
bfd_set_error (bfd_error_malformed_archive);
return NULL;