Skip to content

Commit 66b9332

Browse files
committed
Ensure ELFView only add segments in a Begin/EndBulkAddSegments context
1 parent 24a67b5 commit 66b9332

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

view/elf/elfview.cpp

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -583,6 +583,7 @@ bool ElfView::Init()
583583
vector<Elf64SectionHeader> relocSections, relocASections;
584584
Elf64SectionHeader symbolTableSection;
585585

586+
BeginBulkAddSegments();
586587
uint64_t segmentStart = 0;
587588
for (size_t i = 1; i < m_elfSections.size(); i++)
588589
{
@@ -700,6 +701,8 @@ bool ElfView::Init()
700701
GetParentView()->AddAutoSection(sectionNames[i], m_elfSections[i].offset, m_elfSections[i].size, DefaultSectionSemantics, type, m_elfSections[i].align, m_elfSections[i].entrySize, linkedSection, infoSection, m_elfSections[i].info);
701702
}
702703
}
704+
705+
EndBulkAddSegments();
703706
// Apply architecture and platform
704707
if (!m_arch)
705708
{

0 commit comments

Comments
 (0)