Commit 9d397a6a authored by Thomas White's avatar Thomas White Committed by Thomas White
Browse files

Fix memory leaks

parent 18cb33d0
......@@ -240,6 +240,11 @@ struct detector *get_detector_geometry(const char *filename)
ERROR("Unrecognised field '%s'\n", path[1]);
}
for ( i=0; i<n1; i++ ) free(bits[i]);
for ( i=0; i<n2; i++ ) free(path[i]);
free(bits);
free(path);
} while ( rval != NULL );
if ( det->n_panels == -1 ) {
......
......@@ -474,6 +474,8 @@ skip:
free(powder);
free(cell);
free(intensities);
free(outfile);
free(filename);
return 0;
}
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment