1
0
mirror of https://github.com/opencv/opencv.git synced 2026-07-30 07:43:03 +04:00

Fixed some issues found by static analysis

This commit is contained in:
Maksim Shabunin
2017-09-05 17:10:16 +03:00
parent d25cbaaba8
commit 248e2c7d47
41 changed files with 252 additions and 218 deletions
+3 -1
View File
@@ -573,7 +573,9 @@ Mat LogisticRegressionImpl::remap_labels(const Mat& _labels_i, const map<int, in
for(int i =0;i<labels.rows;i++)
{
new_labels.at<int>(i,0) = lmap.find(labels.at<int>(i,0))->second;
map<int, int>::const_iterator val = lmap.find(labels.at<int>(i,0));
CV_Assert(val != lmap.end());
new_labels.at<int>(i,0) = val->second;
}
return new_labels;
}