Mercurial > hg > orthanc
changeset 6768:ca9a86f8755b
fix warnings
| author | Sebastien Jodogne <s.jodogne@gmail.com> |
|---|---|
| date | Mon, 11 May 2026 18:48:32 +0200 |
| parents | bf0499be7213 |
| children | 76bf4629d797 |
| files | OrthancFramework/Sources/Toolbox.cpp OrthancServer/Plugins/Samples/Common/OrthancPluginCppWrapper.cpp |
| diffstat | 2 files changed, 2 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/OrthancFramework/Sources/Toolbox.cpp Mon May 11 18:25:51 2026 +0200 +++ b/OrthancFramework/Sources/Toolbox.cpp Mon May 11 18:48:32 2026 +0200 @@ -1814,7 +1814,7 @@ const std::string& key, unsigned int defaultValue) { - if (defaultValue > std::numeric_limits<int>::max()) + if (defaultValue > static_cast<unsigned int>(std::numeric_limits<int>::max())) { throw OrthancException(ErrorCode_InternalError, "Default value too large to fit in a int"); }
--- a/OrthancServer/Plugins/Samples/Common/OrthancPluginCppWrapper.cpp Mon May 11 18:25:51 2026 +0200 +++ b/OrthancServer/Plugins/Samples/Common/OrthancPluginCppWrapper.cpp Mon May 11 18:48:32 2026 +0200 @@ -977,7 +977,7 @@ return true; case Json::uintValue: - if (configuration_[key].asUInt() > std::numeric_limits<int>::max()) + if (configuration_[key].asUInt() > static_cast<unsigned int>(std::numeric_limits<int>::max())) { ORTHANC_PLUGINS_LOG_ERROR("The configuration option \"" + GetPath(key) + "\" is too large to fit in an integer");
