[llvm] r268326 - Simplify. NFC.
Rafael Espindola via llvm-commits
llvm-commits at lists.llvm.org
Mon May 2 15:53:32 PDT 2016
Author: rafael
Date: Mon May 2 17:53:32 2016
New Revision: 268326
URL: http://llvm.org/viewvc/llvm-project?rev=268326&view=rev
Log:
Simplify. NFC.
Modified:
llvm/trunk/tools/llvm-ar/llvm-ar.cpp
Modified: llvm/trunk/tools/llvm-ar/llvm-ar.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/tools/llvm-ar/llvm-ar.cpp?rev=268326&r1=268325&r2=268326&view=diff
==============================================================================
--- llvm/trunk/tools/llvm-ar/llvm-ar.cpp (original)
+++ llvm/trunk/tools/llvm-ar/llvm-ar.cpp Mon May 2 17:53:32 2016
@@ -343,12 +343,9 @@ static void doDisplayTable(StringRef Nam
static void doExtract(StringRef Name, const object::Archive::Child &C) {
// Retain the original mode.
sys::fs::perms Mode = C.getAccessMode();
- SmallString<128> Storage = Name;
int FD;
- failIfError(
- sys::fs::openFileForWrite(Storage.c_str(), FD, sys::fs::F_None, Mode),
- Storage.c_str());
+ failIfError(sys::fs::openFileForWrite(Name, FD, sys::fs::F_None, Mode), Name);
{
raw_fd_ostream file(FD, false);
More information about the llvm-commits
mailing list