* layout.cc (Layout::add_comdat): Allow COMDAT group from a replacement
object to override a kept COMDAT group from a plugin object.
This commit is contained in:
parent
a3a219a90a
commit
2756a25828
@ -1,3 +1,8 @@
|
||||
2008-12-10 Cary Coutant <ccoutant@google.com>
|
||||
|
||||
* layout.cc (Layout::add_comdat): Allow COMDAT group from a replacement
|
||||
object to override a kept COMDAT group from a plugin object.
|
||||
|
||||
2008-12-09 Ian Lance Taylor <iant@google.com>
|
||||
|
||||
PR 7088
|
||||
|
@ -47,6 +47,7 @@
|
||||
#include "reloc.h"
|
||||
#include "descriptors.h"
|
||||
#include "layout.h"
|
||||
#include "plugin.h"
|
||||
|
||||
namespace gold
|
||||
{
|
||||
@ -2959,6 +2960,14 @@ Layout::add_comdat(Relobj* object, unsigned int shndx,
|
||||
if (ins.first->second.group_)
|
||||
{
|
||||
// We've already seen a real section group with this signature.
|
||||
// If the kept group is from a plugin object, and we're in
|
||||
// the replacement phase, accept the new one as a replacement.
|
||||
if (ins.first->second.object_ == NULL
|
||||
&& parameters->options().plugins()->in_replacement_phase())
|
||||
{
|
||||
ins.first->second = kept;
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
else if (group)
|
||||
|
Loading…
x
Reference in New Issue
Block a user