Mentions légales du service

Skip to content
Snippets Groups Projects
Commit 2974e009 authored by Mathieu Faverge's avatar Mathieu Faverge
Browse files

Fix coverity issue 1517612 Resource leak

parent 96c6d305
No related branches found
No related tags found
1 merge request!338Fix a bunch of warning reported by coverity on the recents MR
...@@ -126,6 +126,10 @@ testing_zgesvd_desc( run_arg_list_t *args, int check ) ...@@ -126,6 +126,10 @@ testing_zgesvd_desc( run_arg_list_t *args, int check )
/* Fills the matrix with random values */ /* Fills the matrix with random values */
hres = CHAMELEON_zlatms_Tile( ChamDistUniform, seedA, ChamNonsymPosv, D, mode, cond, 1., descA ); hres = CHAMELEON_zlatms_Tile( ChamDistUniform, seedA, ChamNonsymPosv, D, mode, cond, 1., descA );
if ( hres != 0 ) { if ( hres != 0 ) {
free( D );
free( S );
free( U );
free( Vt );
return hres; return hres;
} }
/* /*
...@@ -153,7 +157,6 @@ testing_zgesvd_desc( run_arg_list_t *args, int check ) ...@@ -153,7 +157,6 @@ testing_zgesvd_desc( run_arg_list_t *args, int check )
/* Checks the factorisation and residue */ /* Checks the factorisation and residue */
if ( check ) { if ( check ) {
hres += check_zgesvd( args, jobu, jobvt, descA0, descA, D, S, U, LDU, Vt, LDVt ); hres += check_zgesvd( args, jobu, jobvt, descA0, descA, D, S, U, LDU, Vt, LDVt );
CHAMELEON_Desc_Destroy( &descA0 ); CHAMELEON_Desc_Destroy( &descA0 );
} }
...@@ -162,12 +165,8 @@ testing_zgesvd_desc( run_arg_list_t *args, int check ) ...@@ -162,12 +165,8 @@ testing_zgesvd_desc( run_arg_list_t *args, int check )
CHAMELEON_Desc_Destroy( &descT ); CHAMELEON_Desc_Destroy( &descT );
free( S ); free( S );
free( D ); free( D );
if ( (jobu == ChamAllVec) || (jobu == ChamSVec) ) { free( U );
free( U ); free( Vt );
}
if ( (jobvt == ChamAllVec) || (jobvt == ChamSVec) ) {
free( Vt );
}
return hres; return hres;
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment