Fixed few more warnings/bugs.
This commit is contained in:
parent
e94e5866a1
commit
f6ef504ef0
@ -3564,7 +3564,7 @@ icvReadMat( CvFileStorage* fs, CvFileNode* node )
|
||||
cols = cvReadIntByName( fs, node, "cols", -1 );
|
||||
dt = cvReadStringByName( fs, node, "dt", 0 );
|
||||
|
||||
if( rows < 0 || cols < 0 || dt < 0 )
|
||||
if( rows < 0 || cols < 0 || !dt )
|
||||
CV_Error( CV_StsError, "Some of essential matrix attributes are absent" );
|
||||
|
||||
elem_type = icvDecodeSimpleFormat( dt );
|
||||
@ -4632,7 +4632,7 @@ icvReadGraph( CvFileStorage* fs, CvFileNode* node )
|
||||
if( header_dt )
|
||||
header_size = icvCalcElemSize( header_dt, header_size );
|
||||
|
||||
if( vtx_dt > 0 )
|
||||
if( vtx_dt )
|
||||
{
|
||||
src_vtx_size = icvCalcElemSize( vtx_dt, 0 );
|
||||
vtx_size = icvCalcElemSize( vtx_dt, vtx_size );
|
||||
|
@ -469,7 +469,7 @@ icvCreateGLCMDescriptors_AllowDoubleNest( CvGLCM* destGLCM, int matrixIndex )
|
||||
descriptors[ CV_GLCMDESC_ENERGY ] += entryValue*entryValue;
|
||||
}
|
||||
|
||||
if( marginalProbability>0 )
|
||||
if( marginalProbability[ actualSideLoop1 ] > 0 )
|
||||
marginalProbabilityEntropy += marginalProbability[ actualSideLoop1 ]*log(marginalProbability[ actualSideLoop1 ]);
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user