Skip to content

Commit

Permalink
switch to MAXDWORD
Browse files Browse the repository at this point in the history
  • Loading branch information
strega-nil committed Oct 15, 2021
1 parent 4ebe503 commit 73de331
Showing 1 changed file with 1 addition and 6 deletions.
7 changes: 1 addition & 6 deletions src/vcpkg/base/messages.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -24,12 +24,7 @@ namespace vcpkg::msg
std::abort();
}
}
static DWORD size_to_write(::size_t size)
{
return size > static_cast<DWORD>(-1) // DWORD_MAX
? static_cast<DWORD>(-1)
: static_cast<DWORD>(size);
}
static DWORD size_to_write(::size_t size) { return size > MAXDWORD ? MAXDWORD : static_cast<DWORD>(size); }

void write_unlocalized_text_to_stdout(Color c, StringView sv)
{
Expand Down

0 comments on commit 73de331

Please sign in to comment.