From daef9380857af12aad6a4ffd822fb5d6bf2b1b02 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jes=C3=BAs=20Poderoso?= <120394830+JesusPoderoso@users.noreply.github.com> Date: Mon, 19 Aug 2024 07:46:10 +0200 Subject: [PATCH] Add unsigned specification to literals (#5125) (#5149) Signed-off-by: JesusPoderoso --- include/fastdds/rtps/common/InstanceHandle.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/include/fastdds/rtps/common/InstanceHandle.h b/include/fastdds/rtps/common/InstanceHandle.h index c7dfab81880..ffdfa0ecd8b 100644 --- a/include/fastdds/rtps/common/InstanceHandle.h +++ b/include/fastdds/rtps/common/InstanceHandle.h @@ -299,7 +299,7 @@ inline std::ostream& operator <<( { ss << (int)iHandle.value[i] << "."; } - ss << (int)iHandle.value[15] << std::dec; + ss << (int)iHandle.value[15u] << std::dec; return output << ss.str(); } @@ -332,9 +332,9 @@ inline std::istream& operator >>( input.setstate(std::ios_base::failbit); } - iHandle.value[0] = static_cast(hex); + iHandle.value[0u] = static_cast(hex); - for (int i = 1; i < 16; ++i) + for (uint8_t i = 1; i < 16; ++i) { input >> point >> hex; if ( point != '.' || hex > 255 )