From 0dcd6c7e2fbfe78e4d2f26e01de0d4ea032d8fd6 Mon Sep 17 00:00:00 2001 From: Thomas White Date: Wed, 14 Apr 2021 10:29:04 +0200 Subject: cell_tool: Fix a big memory leak --- src/cell_tool.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'src') diff --git a/src/cell_tool.c b/src/cell_tool.c index 493334b4..8ed674f9 100644 --- a/src/cell_tool.c +++ b/src/cell_tool.c @@ -318,7 +318,10 @@ static int find_ambi(UnitCell *cell, SymOpList *sym, double ltl, double atl) } } - if ( intmat_det(m) != +1 ) continue; + if ( intmat_det(m) != +1 ) { + intmat_free(m); + continue; + } nc = cell_transform_intmat(cell, m); -- cgit v1.2.3