From 50bf643cfb1a89429095be3ffcdd965f1d670561 Mon Sep 17 00:00:00 2001 From: Rui Ueyama Date: Fri, 27 Apr 2018 15:32:04 +0000 Subject: [PATCH] Do not set RequiresNullTerminator. NFC. When reading object files, we don't need '\0' at end of each file. llvm-svn: 331045 --- lld/ELF/InputFiles.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lld/ELF/InputFiles.cpp b/lld/ELF/InputFiles.cpp index 27d39c670d3e..f74a058079b4 100644 --- a/lld/ELF/InputFiles.cpp +++ b/lld/ELF/InputFiles.cpp @@ -63,7 +63,7 @@ Optional elf::readFile(StringRef Path) { log(Path); - auto MBOrErr = MemoryBuffer::getFile(Path); + auto MBOrErr = MemoryBuffer::getFile(Path, -1, false); if (auto EC = MBOrErr.getError()) { error("cannot open " + Path + ": " + EC.message()); return None;