Really fix the type mismatch error in GDBRemoteCommunicationServerCommon

My previous attempt in attempt in r369904 actually broke the 32bit build
because File::Read expects to take a reference to size_t. Fix the
warning by using SIZE_MAX to denote failure instead.

llvm-svn: 369910
This commit is contained in:
Pavel Labath 2019-08-26 13:56:33 +00:00
parent 298c0b352d
commit 341df3f13a
1 changed files with 2 additions and 2 deletions

View File

@ -550,10 +550,10 @@ GDBRemoteCommunicationServerCommon::Handle_vFile_pRead(
packet.SetFilePos(::strlen("vFile:pread:"));
int fd = packet.GetS32(-1);
if (packet.GetChar() == ',') {
uint64_t count = packet.GetU64(UINT64_MAX);
size_t count = packet.GetU64(SIZE_MAX);
if (packet.GetChar() == ',') {
off_t offset = packet.GetU64(UINT32_MAX);
if (count == UINT64_MAX) {
if (count == SIZE_MAX) {
response.Printf("F-1:%i", EINVAL);
return SendPacketNoLock(response.GetString());
}