[lld] r331045 - Do not set RequiresNullTerminator. NFC.

Rui Ueyama via llvm-commits llvm-commits at lists.llvm.org
Fri Apr 27 09:13:10 PDT 2018


Yes, but I'll try to make it default because RequiresNullTerminator doesn't
make sense in most cases, and I think it is just an inappropriate value as
a default.

On Fri, Apr 27, 2018 at 8:55 AM Rafael Avila de Espindola <
rafael.espindola at gmail.com> wrote:

> Thanks!
>
> Maybe add a comment saying what the false is?
>
> Cheers,
> Rafael
>
> Rui Ueyama via llvm-commits <llvm-commits at lists.llvm.org> writes:
>
> > Author: ruiu
> > Date: Fri Apr 27 08:32:04 2018
> > New Revision: 331045
> >
> > URL: http://llvm.org/viewvc/llvm-project?rev=331045&view=rev
> > Log:
> > Do not set RequiresNullTerminator. NFC.
> >
> > When reading object files, we don't need '\0' at end of each file.
> >
> > Modified:
> >     lld/trunk/ELF/InputFiles.cpp
> >
> > Modified: lld/trunk/ELF/InputFiles.cpp
> > URL:
> http://llvm.org/viewvc/llvm-project/lld/trunk/ELF/InputFiles.cpp?rev=331045&r1=331044&r2=331045&view=diff
> >
> ==============================================================================
> > --- lld/trunk/ELF/InputFiles.cpp (original)
> > +++ lld/trunk/ELF/InputFiles.cpp Fri Apr 27 08:32:04 2018
> > @@ -63,7 +63,7 @@ Optional<MemoryBufferRef> elf::readFile(
> >
> >    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;
> >
> >
> > _______________________________________________
> > llvm-commits mailing list
> > llvm-commits at lists.llvm.org
> > http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-commits
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20180427/d8dd0638/attachment.html>


More information about the llvm-commits mailing list