From 7c9dcfb29e5095d560206973c40e6a33ba108c21 Mon Sep 17 00:00:00 2001 From: Rafael Espindola Date: Thu, 19 Jun 2014 22:33:23 +0000 Subject: Simplify. No functionality change. Thanks to Alp Toker for noticing it. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@211320 91177308-0d34-0410-b5e6-96231b3b80d8 --- tools/gold/gold-plugin.cpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'tools') diff --git a/tools/gold/gold-plugin.cpp b/tools/gold/gold-plugin.cpp index e21a82373f..2cde5d1c57 100644 --- a/tools/gold/gold-plugin.cpp +++ b/tools/gold/gold-plugin.cpp @@ -322,8 +322,7 @@ static ld_plugin_status claim_file_hook(const ld_plugin_input_file *file, cf.syms.push_back(ld_plugin_symbol()); ld_plugin_symbol &sym = cf.syms.back(); - sym.name = const_cast(M->getSymbolName(i)); - sym.name = strdup(sym.name); + sym.name = strdup(M->getSymbolName(i)); sym.version = NULL; int scope = attrs & LTO_SYMBOL_SCOPE_MASK; -- cgit v1.2.3