mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-06-12 13:38:21 +00:00
MemoryBuffer now return an error_code and returns a OwningPtr<MemoryBuffer> via an out parm.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@121958 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@ -464,11 +464,6 @@ static void ExpandResponseFiles(unsigned argc, char** argv,
|
||||
const sys::FileStatus *FileStat = respFile.getFileStatus();
|
||||
if (FileStat && FileStat->getSize() != 0) {
|
||||
|
||||
// Mmap the response file into memory.
|
||||
error_code ec;
|
||||
OwningPtr<MemoryBuffer>
|
||||
respFilePtr(MemoryBuffer::getFile(respFile.c_str(), ec));
|
||||
|
||||
// If we could open the file, parse its contents, otherwise
|
||||
// pass the @file option verbatim.
|
||||
|
||||
@ -477,7 +472,9 @@ static void ExpandResponseFiles(unsigned argc, char** argv,
|
||||
// itself contain additional @file options; any such options will be
|
||||
// processed recursively.")
|
||||
|
||||
if (respFilePtr != 0) {
|
||||
// Mmap the response file into memory.
|
||||
OwningPtr<MemoryBuffer> respFilePtr;
|
||||
if (!MemoryBuffer::getFile(respFile.c_str(), respFilePtr)) {
|
||||
ParseCStringVector(newArgv, respFilePtr->getBufferStart());
|
||||
continue;
|
||||
}
|
||||
|
Reference in New Issue
Block a user