From 99a98eefac1aa9f4a3c6b0f3fd614182ec851571 Mon Sep 17 00:00:00 2001 From: Asit Dhal Date: Mon, 14 Dec 2020 04:46:38 +0100 Subject: cmake_policy: Add check for return value of SetPolicyVersion Fixes: #21557 --- Source/cmCMakePolicyCommand.cxx | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/Source/cmCMakePolicyCommand.cxx b/Source/cmCMakePolicyCommand.cxx index b7f08d2..1f99043 100644 --- a/Source/cmCMakePolicyCommand.cxx +++ b/Source/cmCMakePolicyCommand.cxx @@ -191,8 +191,7 @@ bool HandleVersionMode(std::vector const& args, return false; } - status.GetMakefile().SetPolicyVersion(version_min, version_max); - return true; + return status.GetMakefile().SetPolicyVersion(version_min, version_max); } bool HandleGetWarningMode(std::vector const& args, -- cgit v0.12