From 6168c2a1c6636d0897e055d77d807dbd14b34485 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rafael=20=C3=81vila=20de=20Esp=C3=ADndola?= Date: Wed, 17 Sep 2014 17:53:49 -0400 Subject: Fix handling of common symbols with plugins. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit gold/ChangeLog: 2014-09-17 Rafael Ávila de Espíndola * plugin.cc (Sized_pluginobj::do_add_symbols): Ignore isym->size. * resolve.cc (Symbol_table::resolve): Don't override common symbols during the replacement phase. --- gold/plugin.cc | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'gold/plugin.cc') diff --git a/gold/plugin.cc b/gold/plugin.cc index 65197322dd..0339d4289d 100644 --- a/gold/plugin.cc +++ b/gold/plugin.cc @@ -1053,8 +1053,6 @@ Sized_pluginobj::do_add_symbols(Symbol_table* symtab, elfcpp::Sym sym(symbuf); elfcpp::Sym_write osym(symbuf); - typedef typename elfcpp::Elf_types::Elf_WXword Elf_size_type; - this->symbols_.resize(this->nsyms_); for (int i = 0; i < this->nsyms_; ++i) @@ -1125,7 +1123,7 @@ Sized_pluginobj::do_add_symbols(Symbol_table* symtab, osym.put_st_name(0); osym.put_st_value(0); - osym.put_st_size(static_cast(isym->size)); + osym.put_st_size(0); osym.put_st_info(bind, elfcpp::STT_NOTYPE); osym.put_st_other(vis, 0); osym.put_st_shndx(shndx); -- cgit v1.2.3