From 20b6d3d0d312f6dffbd795011d6568db7f1403d4 Mon Sep 17 00:00:00 2001 From: Rafael Espindola Date: Wed, 23 Nov 2016 19:16:20 +0000 Subject: [PATCH] Fix this on 32 bit hosts. Looks like we have no 32 bit bot that builds with mips support. llvm-svn: 287799 --- lld/ELF/SyntheticSections.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lld/ELF/SyntheticSections.cpp b/lld/ELF/SyntheticSections.cpp index 17a7ffdb..5918f0b 100644 --- a/lld/ELF/SyntheticSections.cpp +++ b/lld/ELF/SyntheticSections.cpp @@ -178,7 +178,7 @@ template void MipsOptionsSection::writeTo(uint8_t *Buf) { if (!Config->Relocatable) Reginfo.ri_gp_value = In::MipsGot->getVA() + MipsGPOffset; - memcpy(Buf + sizeof(Options), &Reginfo, sizeof(Reginfo)); + memcpy(Buf + sizeof(typename ELFT::uint), &Reginfo, sizeof(Reginfo)); } template -- 2.7.4