From 17356024a2e59983996be53dec175d9f37f65216 Mon Sep 17 00:00:00 2001 From: thirumalai-qcom Date: Fri, 26 Jul 2024 10:15:59 +0530 Subject: [PATCH] Requests: Fix min/max to be used from limits Updated the code to use min/max from limits to avoid potential compilation Issues on WOA devices. --- src/requesthandler/RequestHandler_SceneItems.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/requesthandler/RequestHandler_SceneItems.cpp b/src/requesthandler/RequestHandler_SceneItems.cpp index 146fb654..b6670286 100644 --- a/src/requesthandler/RequestHandler_SceneItems.cpp +++ b/src/requesthandler/RequestHandler_SceneItems.cpp @@ -440,7 +440,7 @@ RequestResult RequestHandler::SetSceneItemTransform(const Request &request) } if (r.Contains("alignment")) { - if (!r.ValidateOptionalNumber("alignment", statusCode, comment, 0, std::numeric_limits::max())) + if (!r.ValidateOptionalNumber("alignment", statusCode, comment, 0, (std::numeric_limits::max)())) return RequestResult::Error(statusCode, comment); sceneItemTransform.alignment = r.RequestData["alignment"]; transformChanged = true; @@ -458,7 +458,7 @@ RequestResult RequestHandler::SetSceneItemTransform(const Request &request) } if (r.Contains("boundsAlignment")) { - if (!r.ValidateOptionalNumber("boundsAlignment", statusCode, comment, 0, std::numeric_limits::max())) + if (!r.ValidateOptionalNumber("boundsAlignment", statusCode, comment, 0, (std::numeric_limits::max)())) return RequestResult::Error(statusCode, comment); sceneItemTransform.bounds_alignment = r.RequestData["boundsAlignment"]; transformChanged = true;