diff options
author | Chris Mahoney <chris.mahoney@kitware.com> | 2023-08-09 18:28:09 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2023-11-17 23:41:41 (GMT) |
commit | 8c307ab5670877454572f9e0b3cdc4ae58cefd7b (patch) | |
tree | 2d3965f91363d4b8b072fa6db919ca885bbc5864 /Source/CTest/cmCTestMultiProcessHandler.cxx | |
parent | 1f8f270f625d32486d1af7e7eac691bcafb5c2e4 (diff) | |
download | CMake-8c307ab5670877454572f9e0b3cdc4ae58cefd7b.zip CMake-8c307ab5670877454572f9e0b3cdc4ae58cefd7b.tar.gz CMake-8c307ab5670877454572f9e0b3cdc4ae58cefd7b.tar.bz2 |
cmCTestMultiProcessHandler: Replace false condition with opposite assert
Diffstat (limited to 'Source/CTest/cmCTestMultiProcessHandler.cxx')
-rw-r--r-- | Source/CTest/cmCTestMultiProcessHandler.cxx | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/Source/CTest/cmCTestMultiProcessHandler.cxx b/Source/CTest/cmCTestMultiProcessHandler.cxx index 24e8569..b82e968 100644 --- a/Source/CTest/cmCTestMultiProcessHandler.cxx +++ b/Source/CTest/cmCTestMultiProcessHandler.cxx @@ -156,9 +156,7 @@ bool cmCTestMultiProcessHandler::StartTestProcess(int test) { if (this->HaveAffinity && this->Properties[test]->WantAffinity) { size_t needProcessors = this->GetProcessorsUsed(test); - if (needProcessors > this->ProcessorsAvailable.size()) { - return false; - } + assert(needProcessors <= this->ProcessorsAvailable.size()); std::vector<size_t> affinity; affinity.reserve(needProcessors); for (size_t i = 0; i < needProcessors; ++i) { |