diff --git a/.github/workflows/coverage-linux.yml b/.github/workflows/coverage-linux.yml index c8b740db801169..2ee6c8b5f19b77 100644 --- a/.github/workflows/coverage-linux.yml +++ b/.github/workflows/coverage-linux.yml @@ -8,7 +8,6 @@ on: - 'benchmark/**' - 'deps/**' - 'doc/**' - - 'tools/**' push: branches: - master @@ -18,7 +17,6 @@ on: - 'benchmark/**' - 'deps/**' - 'doc/**' - - 'tools/**' env: PYTHON_VERSION: 3.9 diff --git a/tools/inspector_protocol/encoding/encoding.cc b/tools/inspector_protocol/encoding/encoding.cc index 1513767a85592b..636281dd8ad894 100644 --- a/tools/inspector_protocol/encoding/encoding.cc +++ b/tools/inspector_protocol/encoding/encoding.cc @@ -831,8 +831,9 @@ void CBORTokenizer::ReadNextToken(bool enter_envelope) { // inspector_protocol, it's not a CBOR limitation), so we check // against the signed max, so that the allowable values are // 0, 1, 2, ... 2^31 - 1. - if (!bytes_read || std::numeric_limits::max() < - token_start_internal_value_) { + if (!bytes_read || + static_cast(std::numeric_limits::max()) < + static_cast(token_start_internal_value_)) { SetError(Error::CBOR_INVALID_INT32); return; } @@ -849,8 +850,9 @@ void CBORTokenizer::ReadNextToken(bool enter_envelope) { // We check the the payload in token_start_internal_value_ against // that range (2^31-1 is also known as // std::numeric_limits::max()). - if (!bytes_read || token_start_internal_value_ > - std::numeric_limits::max()) { + if (!bytes_read || + static_cast(token_start_internal_value_) > + static_cast(std::numeric_limits::max())) { SetError(Error::CBOR_INVALID_INT32); return; } diff --git a/tools/inspector_protocol/lib/encoding_cpp.template b/tools/inspector_protocol/lib/encoding_cpp.template index e950acd6a6f34d..d3646491140663 100644 --- a/tools/inspector_protocol/lib/encoding_cpp.template +++ b/tools/inspector_protocol/lib/encoding_cpp.template @@ -839,8 +839,9 @@ void CBORTokenizer::ReadNextToken(bool enter_envelope) { // inspector_protocol, it's not a CBOR limitation), so we check // against the signed max, so that the allowable values are // 0, 1, 2, ... 2^31 - 1. - if (!bytes_read || std::numeric_limits::max() < - token_start_internal_value_) { + if (!bytes_read || + static_cast(std::numeric_limits::max()) < + static_cast(token_start_internal_value_)) { SetError(Error::CBOR_INVALID_INT32); return; } @@ -857,8 +858,9 @@ void CBORTokenizer::ReadNextToken(bool enter_envelope) { // We check the the payload in token_start_internal_value_ against // that range (2^31-1 is also known as // std::numeric_limits::max()). - if (!bytes_read || token_start_internal_value_ > - std::numeric_limits::max()) { + if (!bytes_read || + static_cast(token_start_internal_value_) > + static_cast(std::numeric_limits::max())) { SetError(Error::CBOR_INVALID_INT32); return; }