diff options
author | Chris Lattner <sabre@nondot.org> | 2009-07-12 19:01:16 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2009-07-12 19:01:16 +0000 |
commit | a3c69aeb657413fdb831f3a4de2873b7be6a1e53 (patch) | |
tree | 19d471804f648983552dc8e7c5844bfb2f50f973 /llvm/lib/System/Unix | |
parent | d37908f14988f8d00d25893e1f9ce99737d6efa3 (diff) | |
download | bcm5719-llvm-a3c69aeb657413fdb831f3a4de2873b7be6a1e53.tar.gz bcm5719-llvm-a3c69aeb657413fdb831f3a4de2873b7be6a1e53.zip |
"UNIX paths can contain non-ASCII characters, so Path::isValid() should not reject paths with such characters in them. The attached patch removes the check from Path::isValid()."
patch by Benjamin Kramer!
llvm-svn: 75421
Diffstat (limited to 'llvm/lib/System/Unix')
-rw-r--r-- | llvm/lib/System/Unix/Path.inc | 10 |
1 files changed, 1 insertions, 9 deletions
diff --git a/llvm/lib/System/Unix/Path.inc b/llvm/lib/System/Unix/Path.inc index 1f73571cf14..125a0ab209c 100644 --- a/llvm/lib/System/Unix/Path.inc +++ b/llvm/lib/System/Unix/Path.inc @@ -92,15 +92,7 @@ Path::isValid() const { // Check some obvious things if (path.empty()) return false; - else if (path.length() >= MAXPATHLEN) - return false; - - // Check that the characters are ascii chars - size_t len = path.length(); - unsigned i = 0; - while (i < len && isascii(path[i])) - ++i; - return i >= len; + return path.length() < MAXPATHLEN; } bool |