summaryrefslogtreecommitdiffstats
path: root/Modules
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2022-03-08 13:22:02 (GMT)
committerKitware Robot <kwrobot@kitware.com>2022-03-08 13:22:09 (GMT)
commit1d9b545390cef6fbf188c57db5f269c66871cb52 (patch)
treeb63776cbeef4838f0f11e71e8b122608589a8802 /Modules
parent7a8536e0eab97d5467dbcca9b14f1a9deaf934ae (diff)
parentbb2c7b7dc05c15ac929db54a3c5931ddab4867a3 (diff)
downloadCMake-1d9b545390cef6fbf188c57db5f269c66871cb52.zip
CMake-1d9b545390cef6fbf188c57db5f269c66871cb52.tar.gz
CMake-1d9b545390cef6fbf188c57db5f269c66871cb52.tar.bz2
Merge topic 'FindMatlab-minver' into release-3.23
bb2c7b7dc0 FindMatlab: Fix logic error when minimum version is not found Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !7047
Diffstat (limited to 'Modules')
-rw-r--r--Modules/FindMatlab.cmake1
1 files changed, 1 insertions, 0 deletions
diff --git a/Modules/FindMatlab.cmake b/Modules/FindMatlab.cmake
index f0e991b..3c7efbc 100644
--- a/Modules/FindMatlab.cmake
+++ b/Modules/FindMatlab.cmake
@@ -1573,6 +1573,7 @@ if(_numbers_of_matlab_roots GREATER 0)
list(GET _matlab_possible_roots ${_list_index} Matlab_VERSION_STRING)
list(GET _matlab_possible_roots ${_matlab_root_dir_index} Matlab_ROOT_DIR)
elseif(DEFINED Matlab_FIND_VERSION)
+ set(_list_index -1)
foreach(_matlab_root_index RANGE 1 ${_numbers_of_matlab_roots} 3)
list(GET _matlab_possible_roots ${_matlab_root_index} _matlab_root_version)
if(_matlab_root_version VERSION_GREATER_EQUAL Matlab_FIND_VERSION)