* archive.cc (Archive::include_all_members) Correct to step
authorCary Coutant <ccoutant@google.com>
Fri, 30 May 2008 21:24:43 +0000 (21:24 +0000)
committerCary Coutant <ccoutant@google.com>
Fri, 30 May 2008 21:24:43 +0000 (21:24 +0000)
over symbol table and extended name table in thin archives.

gold/ChangeLog
gold/archive.cc

index 0fb667d1e4adda2fecc9fe7990a4e70a2a5fa9d9..74eb045f570c588d614a9e866c41cb6fd040ff52 100644 (file)
@@ -1,3 +1,8 @@
+2008-05-30  Cary Coutant  <ccoutant@google.com>
+
+       * archive.cc (Archive::include_all_members) Correct to step
+       over symbol table and extended name table in thin archives.
+
 2008-05-29  Kris Van Hees  <kris.van.hees@oracle.com>
 
        PR 6407
index 0ff8aee2075bd1a3216e0c6c2151c578f2b082c3..737f3e21729141f49dbaa807a0c96e5b2d647ca9 100644 (file)
@@ -386,20 +386,23 @@ Archive::include_all_members(Symbol_table* symtab, Layout* layout,
        reinterpret_cast<const Archive_header*>(hdr_buf);
       std::string name;
       off_t size = this->interpret_header(hdr, off, &name, NULL);
+      bool special_member = false;
       if (name.empty())
         {
           // Symbol table.
+          special_member = true;
         }
       else if (name == "/")
         {
           // Extended name table.
+          special_member = true;
         }
       else
         this->include_member(symtab, layout, input_objects, off,
                             mapfile, NULL, "--whole-archive");
 
       off += sizeof(Archive_header);
-      if (!this->is_thin_archive_)
+      if (special_member || !this->is_thin_archive_)
         off += size;
       if ((off & 1) != 0)
         ++off;
This page took 0.029685 seconds and 4 git commands to generate.