diff options
-rw-r--r-- | lld/ELF/InputFiles.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lld/ELF/InputFiles.cpp b/lld/ELF/InputFiles.cpp index c8bcd739ff6..de7e1034852 100644 --- a/lld/ELF/InputFiles.cpp +++ b/lld/ELF/InputFiles.cpp @@ -450,7 +450,7 @@ SymbolBody *elf::ObjectFile<ELFT>::createSymbolBody(const Elf_Sym *Sym) { if (this->StringTable.size() <= Sym->st_name) fatal(toString(this) + ": invalid symbol name offset"); - const char *Name = this->StringTable.data() + Sym->st_name; + StringRefZ Name = this->StringTable.data() + Sym->st_name; if (Sym->st_shndx == SHN_UNDEF) return new (BAlloc) Undefined(Name, /*IsLocal=*/true, StOther, Type, this); |