From 5221516a04d06e041939b1610b91345badfecb55 Mon Sep 17 00:00:00 2001 From: Rafael Espindola Date: Fri, 22 Apr 2016 11:46:28 +0000 Subject: [PATCH] Simplify. NFC. llvm-svn: 267147 --- lld/ELF/MarkLive.cpp | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/lld/ELF/MarkLive.cpp b/lld/ELF/MarkLive.cpp index cbc5fd2..2511fc1 100644 --- a/lld/ELF/MarkLive.cpp +++ b/lld/ELF/MarkLive.cpp @@ -50,12 +50,10 @@ static void forEachSuccessor(InputSection *Sec, for (const Elf_Shdr *RelSec : Sec->RelocSections) { if (RelSec->sh_type == SHT_RELA) { for (const Elf_Rela &RI : Obj.relas(RelSec)) - if (InputSectionBase *Succ = Sec->getRelocTarget(RI)) - Fn(Succ); + Fn(Sec->getRelocTarget(RI)); } else { for (const Elf_Rel &RI : Obj.rels(RelSec)) - if (InputSectionBase *Succ = Sec->getRelocTarget(RI)) - Fn(Succ); + Fn(Sec->getRelocTarget(RI)); } } } -- 2.7.4