[llvm] r257430 - lli: Fix warnings. [-Wsign-compare]
NAKAMURA Takumi via llvm-commits
llvm-commits at lists.llvm.org
Mon Jan 11 17:23:30 PST 2016
Author: chapuni
Date: Mon Jan 11 19:23:30 2016
New Revision: 257430
URL: http://llvm.org/viewvc/llvm-project?rev=257430&view=rev
Log:
lli: Fix warnings. [-Wsign-compare]
Modified:
llvm/trunk/tools/lli/RemoteJITUtils.h
Modified: llvm/trunk/tools/lli/RemoteJITUtils.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/tools/lli/RemoteJITUtils.h?rev=257430&r1=257429&r2=257430&view=diff
==============================================================================
--- llvm/trunk/tools/lli/RemoteJITUtils.h (original)
+++ llvm/trunk/tools/lli/RemoteJITUtils.h Mon Jan 11 19:23:30 2016
@@ -31,7 +31,7 @@ public:
std::error_code readBytes(char *Dst, unsigned Size) override {
assert(Dst && "Attempt to read into null.");
ssize_t ReadResult = ::read(InFD, Dst, Size);
- if (ReadResult != Size)
+ if (ReadResult != (ssize_t)Size)
return std::error_code(errno, std::generic_category());
return std::error_code();
}
@@ -39,7 +39,7 @@ public:
std::error_code appendBytes(const char *Src, unsigned Size) override {
assert(Src && "Attempt to append from null.");
ssize_t WriteResult = ::write(OutFD, Src, Size);
- if (WriteResult != Size)
+ if (WriteResult != (ssize_t)Size)
std::error_code(errno, std::generic_category());
return std::error_code();
}
More information about the llvm-commits
mailing list