aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--tools/llvm-ar/llvm-ar.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/tools/llvm-ar/llvm-ar.cpp b/tools/llvm-ar/llvm-ar.cpp
index e56e49ad..64ef3fa 100644
--- a/tools/llvm-ar/llvm-ar.cpp
+++ b/tools/llvm-ar/llvm-ar.cpp
@@ -877,9 +877,9 @@ int main(int argc, char **argv) {
);
StringRef Stem = sys::path::stem(ToolName);
- if (Stem.endswith("ar"))
+ if (Stem.find("ar") != StringRef::npos)
return ar_main(argv);
- if (Stem.endswith("ranlib"))
+ if (Stem.find("ranlib") != StringRef::npos)
return ranlib_main();
fail("Not ranlib or ar!");
}