[lld] r297012 - Fix -Wc++11-narrowing.
Rui Ueyama via llvm-commits
llvm-commits at lists.llvm.org
Mon Mar 6 07:16:18 PST 2017
Author: ruiu
Date: Mon Mar 6 09:16:18 2017
New Revision: 297012
URL: http://llvm.org/viewvc/llvm-project?rev=297012&view=rev
Log:
Fix -Wc++11-narrowing.
Modified:
lld/trunk/ELF/Relocations.cpp
Modified: lld/trunk/ELF/Relocations.cpp
URL: http://llvm.org/viewvc/llvm-project/lld/trunk/ELF/Relocations.cpp?rev=297012&r1=297011&r2=297012&view=diff
==============================================================================
--- lld/trunk/ELF/Relocations.cpp (original)
+++ lld/trunk/ELF/Relocations.cpp Mon Mar 6 09:16:18 2017
@@ -480,7 +480,7 @@ template <class ELFT> static void addCop
// memory protection by reserving space in the .bss.rel.ro section.
bool IsReadOnly = isReadOnly<ELFT>(SS);
BssRelSection<ELFT> *RelSec = IsReadOnly ? In<ELFT>::BssRelRo : In<ELFT>::Bss;
- size_t Off = RelSec->addCopyRelocation(SS->getAlignment<ELFT>(), SymSize);
+ uintX_t Off = RelSec->addCopyRelocation(SS->getAlignment<ELFT>(), SymSize);
// Look through the DSO's dynamic symbol table for aliases and create a
// dynamic symbol for each one. This causes the copy relocation to correctly
More information about the llvm-commits
mailing list