diff --git a/snapshot/win/process_reader_win.cc b/snapshot/win/process_reader_win.cc index 373124d6..f3b63237 100644 --- a/snapshot/win/process_reader_win.cc +++ b/snapshot/win/process_reader_win.cc @@ -136,7 +136,7 @@ bool FillThreadContextAndSuspendCount(HANDLE thread_handle, CaptureContext(&thread->context.native); } else { DWORD previous_suspend_count = SuspendThread(thread_handle); - if (previous_suspend_count == -1) { + if (previous_suspend_count == static_cast(-1)) { PLOG(ERROR) << "SuspendThread"; return false; } diff --git a/util/win/exception_handler_server.cc b/util/win/exception_handler_server.cc index 47815cea..4273523f 100644 --- a/util/win/exception_handler_server.cc +++ b/util/win/exception_handler_server.cc @@ -347,7 +347,7 @@ std::wstring ExceptionHandlerServer::CreatePipe() { void ExceptionHandlerServer::Run(Delegate* delegate) { uint64_t shutdown_token = base::RandUint64(); ScopedKernelHANDLE thread_handles[kPipeInstances]; - for (int i = 0; i < arraysize(thread_handles); ++i) { + for (size_t i = 0; i < arraysize(thread_handles); ++i) { HANDLE pipe; if (first_pipe_instance_.is_valid()) { pipe = first_pipe_instance_.release(); @@ -399,7 +399,7 @@ void ExceptionHandlerServer::Run(Delegate* delegate) { } // Signal to the named pipe instances that they should terminate. - for (int i = 0; i < arraysize(thread_handles); ++i) { + for (size_t i = 0; i < arraysize(thread_handles); ++i) { ClientToServerMessage message; memset(&message, 0, sizeof(message)); message.type = ClientToServerMessage::kShutdown;