Commit 9d64aede authored by godog's avatar godog

ssotool: close fp on error

found when playing with https://github.com/facebook/infer
parent 6769373c
......@@ -61,6 +61,7 @@ static size_t read_from_file(const char *path, unsigned char **out) {
*out = (unsigned char *)malloc(sz + 1);
if (0 >= fread(*out, 1, sz, fp)) {
fclose(fp);
return -1;
}
(*out)[sz] = 0;
......
Markdown is supported
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