Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(2915)

Unified Diff: bfd/archive64.c

Issue 124383005: GDB 7.6.50 (Closed) Base URL: http://git.chromium.org/native_client/nacl-gdb.git@upstream
Patch Set: Created 6 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « bfd/archive.c ('k') | bfd/archures.c » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: bfd/archive64.c
diff --git a/bfd/archive64.c b/bfd/archive64.c
index f3a13d341ebe3d1674ee207175ed0fe7c13be2d7..be64e0d373d82fe351d57c4b4d96dda1940448d3 100644
--- a/bfd/archive64.c
+++ b/bfd/archive64.c
@@ -1,6 +1,5 @@
-/* MIPS-specific support for 64-bit ELF
- Copyright 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2005, 2006, 2007,
- 2010, 2012 Free Software Foundation, Inc.
+/* Support for 64-bit ELF archives.
+ Copyright 1996-2013 Free Software Foundation, Inc.
Ian Lance Taylor, Cygnus Support
Linker support added by Mark Mitchell, CodeSourcery, LLC.
<mark@codesourcery.com>
@@ -77,7 +76,7 @@ bfd_elf64_archive_slurp_armap (bfd *abfd)
if (mapdata == NULL)
return FALSE;
parsed_size = mapdata->parsed_size;
- bfd_release (abfd, mapdata);
+ free (mapdata);
if (bfd_bread (int_buf, 8, abfd) != 8)
{
@@ -200,7 +199,7 @@ bfd_elf64_archive_write_armap (bfd *arch,
current = current->archive_next)
{
/* For each symbol which is used defined in this object, write out
- the object file's address in the archive */
+ the object file's address in the archive. */
for (;
count < symbol_count && map[count].u.abfd == current;
@@ -210,9 +209,11 @@ bfd_elf64_archive_write_armap (bfd *arch,
if (bfd_bwrite (buf, 8, arch) != 8)
return FALSE;
}
+
/* Add size of this archive entry */
- archive_member_file_ptr += (arelt_size (current)
- + sizeof (struct ar_hdr));
+ archive_member_file_ptr += sizeof (struct ar_hdr);
+ if (! bfd_is_thin_archive (arch))
+ archive_member_file_ptr += arelt_size (current);
/* remember about the even alignment */
archive_member_file_ptr += archive_member_file_ptr % 2;
}
« no previous file with comments | « bfd/archive.c ('k') | bfd/archures.c » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698