summaryrefslogtreecommitdiffstats
path: root/llvm/tools
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2009-02-05 17:58:39 +0000
committerChris Lattner <sabre@nondot.org>2009-02-05 17:58:39 +0000
commit413a0246f8d360a62cbc57be964bd2d1f6879c21 (patch)
tree789e2ad7b3485eb986dd8d0b9b4aa3704641333a /llvm/tools
parentcc41c07227b322a67f2193c41f34f011ee118f59 (diff)
downloadbcm5719-llvm-413a0246f8d360a62cbc57be964bd2d1f6879c21.tar.gz
bcm5719-llvm-413a0246f8d360a62cbc57be964bd2d1f6879c21.zip
fix PR3488: llvm-ar r doesn't replace existing files
Patch by Daniel Shelton! llvm-svn: 63870
Diffstat (limited to 'llvm/tools')
-rw-r--r--llvm/tools/llvm-ar/llvm-ar.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/tools/llvm-ar/llvm-ar.cpp b/llvm/tools/llvm-ar/llvm-ar.cpp
index a6611a3e809..766d91cbd9c 100644
--- a/llvm/tools/llvm-ar/llvm-ar.cpp
+++ b/llvm/tools/llvm-ar/llvm-ar.cpp
@@ -638,7 +638,7 @@ doReplaceOrInsert(std::string* ErrMsg) {
const sys::FileStatus *si = PwS.getFileStatus(false, &Err);
if (!si)
return true;
- if (si->isDir) {
+ if (!si->isDir) {
if (OnlyUpdate) {
// Replace the item only if it is newer.
if (si->modTime > I->getModTime())
OpenPOWER on IntegriCloud