summaryrefslogtreecommitdiff
path: root/lib/Support
diff options
context:
space:
mode:
authorNAKAMURA Takumi <geek4civic@gmail.com>2011-03-07 00:12:53 +0000
committerNAKAMURA Takumi <geek4civic@gmail.com>2011-03-07 00:12:53 +0000
commit19b6c73878c85aca52be869c47b9af3c8efbbdad (patch)
tree92725ecd58772f10994765997ccc24da761af38e /lib/Support
parent1b5ec068f5f068e4b8e600007e2fa126fafe796f (diff)
Windows/PathV2.inc: Eliminate redundant condition. DWORD is unsigned.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@127140 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Support')
-rw-r--r--lib/Support/Windows/PathV2.inc2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/Support/Windows/PathV2.inc b/lib/Support/Windows/PathV2.inc
index 8effb0c737d..8f306d19fe1 100644
--- a/lib/Support/Windows/PathV2.inc
+++ b/lib/Support/Windows/PathV2.inc
@@ -649,7 +649,7 @@ error_code get_magic(const Twine &path, uint32_t len,
::CloseHandle(file);
if (!read_success || (bytes_read != len)) {
// Set result size to the number of bytes read if it's valid.
- if (bytes_read >= 0 && bytes_read <= len)
+ if (bytes_read <= len)
result.set_size(bytes_read);
// ERROR_HANDLE_EOF is mapped to errc::value_too_large.
return ec;