LibELF: Use StringBuilder::string_view() to avoid String allocation

This commit is contained in:
Idan Horowitz 2022-02-15 21:14:15 +02:00 committed by Andreas Kling
commit 7bd409dbdf
Notes: sideshowbarker 2024-07-17 18:41:03 +09:00

View file

@ -251,7 +251,7 @@ Optional<Image::RelocationSection> Image::Section::relocations() const
builder.append(".rel"sv);
builder.append(name());
auto relocation_section = m_image.lookup_section(builder.to_string());
auto relocation_section = m_image.lookup_section(builder.string_view());
if (!relocation_section.has_value())
return {};