[PATCH] D97757: [lld-macho] Rework length check when opening input files
Greg McGary via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Mar 2 01:29:39 PST 2021
gkm created this revision.
gkm added a reviewer: lld-macho.
Herald added a reviewer: int3.
Herald added a project: lld-macho.
gkm requested review of this revision.
Herald added a project: LLVM.
Herald added a subscriber: llvm-commits.
This reverts diff D97610 <https://reviews.llvm.org/D97610> (commit 0223ab035c199e537a0040857ba147ced87fd533 <https://reviews.llvm.org/rG0223ab035c199e537a0040857ba147ced87fd533>) and adds a one-line fix to verify that a `MemoryBufferRef` has sufficient length before reading a 4-byte magic number.
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D97757
Files:
lld/MachO/Driver.cpp
lld/MachO/DriverUtils.cpp
lld/MachO/InputFiles.cpp
lld/MachO/InputFiles.h
lld/test/MachO/invalid/tiny-input.s
lld/test/MachO/rename.s
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D97757.327384.patch
Type: text/x-patch
Size: 7699 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20210302/f7a7bf96/attachment-0001.bin>
More information about the llvm-commits
mailing list