Skip to content

Commit

Permalink
Free info struct in qdldl interface on return with error
Browse files Browse the repository at this point in the history
  • Loading branch information
imciner2 committed Aug 24, 2019
1 parent edb7e05 commit cee5711
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion lin_sys/direct/qdldl/qdldl_interface.c
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,11 @@ static c_int permute_KKT(csc ** KKT, qdldl_solver * p, c_int Pnz, c_int Anz, c_i
#else
amd_status = amd_order((*KKT)->n, (*KKT)->p, (*KKT)->i, p->P, (c_float *)OSQP_NULL, info);
#endif
if (amd_status < 0) return (amd_status);
if (amd_status < 0) {
// Free Amd info and return an error
c_free(info);
return amd_status;
}


// Inverse of the permutation vector
Expand Down

0 comments on commit cee5711

Please sign in to comment.