diff --git a/shell/platform/windows/platform_handler.cc b/shell/platform/windows/platform_handler.cc index 197de59345351..48ebf0cf0411b 100644 --- a/shell/platform/windows/platform_handler.cc +++ b/shell/platform/windows/platform_handler.cc @@ -60,7 +60,7 @@ class ScopedGlobalMemory { memory_ = ::GlobalAlloc(flags, bytes); if (!memory_) { FML_LOG(ERROR) << "Unable to allocate global memory: " - << ::GetLastError(); + << static_cast(::GetLastError()); } } @@ -68,7 +68,7 @@ class ScopedGlobalMemory { if (memory_) { if (::GlobalFree(memory_) != nullptr) { FML_LOG(ERROR) << "Failed to free global allocation: " - << ::GetLastError(); + << static_cast(::GetLastError()); } } } @@ -175,12 +175,12 @@ std::variant ScopedClipboard::GetString() { HANDLE data = ::GetClipboardData(CF_UNICODETEXT); if (data == nullptr) { - return ::GetLastError(); + return static_cast(::GetLastError()); } ScopedGlobalLock locked_data(data); if (!locked_data.get()) { - return ::GetLastError(); + return static_cast(::GetLastError()); } return static_cast(locked_data.get()); }