Merge pull request #270 from VectorCamp/bugfix/cppcheck-redundantAssignment

Fix marked as false positive redundantAssignment cppcheck warnings
This commit is contained in:
Konstantinos Margaritis 2024-05-13 10:25:53 +03:00 committed by GitHub
commit 98bd92ddbc
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -132,7 +132,7 @@ void ComponentRepeat::notePositions(GlushkovBuildState &bs) {
posFirst = bs.getBuilder().numVertices();
sub_comp->notePositions(bs);
u32 copies = m_max < NoLimit ? m_max : MAX(m_min, 1);
u32 copies = (m_max < NoLimit) ? m_max : std::max(m_min, 1U);
DEBUG_PRINTF("building %u copies of repeated region\n", copies);
m_firsts.clear();
m_lasts.clear();