Skip to content

Commit

Permalink
Fix a comparison with a sign mismatch (#309)
Browse files Browse the repository at this point in the history
This is a backport of #288 for Dashing.

Signed-off-by: Scott K Logan <logans@cottsay.net>
  • Loading branch information
cottsay authored Jul 31, 2019
1 parent 8872456 commit 1305dcf
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion rmw_fastrtps_shared_cpp/src/qos.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ bool fill_entity_qos_from_profile(
eprosima::fastrtps::KEEP_LAST_HISTORY_QOS == history_qos.kind &&
static_cast<size_t>(history_qos.depth) < qos_policies.depth)
{
if (qos_policies.depth > (std::numeric_limits<int32_t>::max)()) {
if (qos_policies.depth > static_cast<size_t>((std::numeric_limits<int32_t>::max)())) {
RMW_SET_ERROR_MSG(
"failed to set history depth since the requested queue size exceeds the DDS type");
return false;
Expand Down

0 comments on commit 1305dcf

Please sign in to comment.