diff --git a/apps/regression/model/trigonometric_model.cpp b/apps/regression/model/trigonometric_model.cpp index 25ea7ee778a..b0f7ac17340 100644 --- a/apps/regression/model/trigonometric_model.cpp +++ b/apps/regression/model/trigonometric_model.cpp @@ -151,7 +151,7 @@ static void findExtrema(double* xMinExtremum, double* xMaxExtremum, foundMin = foundMin && foundMax; } if (foundMin && foundMax) { - return; // Two extremum have been found + break; // Two extremum have been found } lastMinExtremum++; lastMaxExtremum++;