git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@141534
91177308-0d34-0410-b5e6-
96231b3b80d8
OwningPtr<Binary> child;
if (error_code ec = i->getAsBinary(child)) {
// Try opening it as a bitcode file.
- MemoryBuffer *buff = i->getBuffer();
+ OwningPtr<MemoryBuffer> buff(i->getBuffer());
Module *Result = 0;
if (buff)
- Result = ParseBitcodeFile(buff, Context, &ErrorMessage);
+ Result = ParseBitcodeFile(buff.get(), Context, &ErrorMessage);
if (Result) {
DumpSymbolNamesFromModule(Result);