Fixed several issues found by static analysis

This commit is contained in:
Maksim Shabunin 2021-02-24 20:31:00 +03:00
parent 67b6ef4c2a
commit b2321576bc
3 changed files with 3 additions and 2 deletions

View File

@ -72,6 +72,7 @@ private:
cv::Matx<double, 9, 1> r_hat;
cv::Matx<double, 3, 1> t;
double sq_error;
SQPSolution() : sq_error(0) {}
};
/*

View File

@ -750,7 +750,7 @@ virtual Ptr<BackendNode> initNgraph(const std::vector<Ptr<BackendWrapper> >& inp
if (max_elem!=last)
{
dstData[x0] = *max_elem;
if( compMaxIdx )
if( compMaxIdx && dstMaskData )
{
dstMaskData[x0] = std::distance(first, max_elem);
}

View File

@ -309,7 +309,7 @@ class SourceReaderCB : public IMFSourceReaderCallback
{
public:
SourceReaderCB() :
m_nRefCount(0), m_hEvent(CreateEvent(NULL, FALSE, FALSE, NULL)), m_bEOS(FALSE), m_hrStatus(S_OK), m_reader(NULL), m_dwStreamIndex(0)
m_nRefCount(0), m_hEvent(CreateEvent(NULL, FALSE, FALSE, NULL)), m_bEOS(FALSE), m_hrStatus(S_OK), m_reader(NULL), m_dwStreamIndex(0), m_lastSampleTimestamp(0)
{
}