ui-tree: free read_sha1_file() buffer after use

Free up the buffer allocated in read_sha1_file()

Signed-off-by: Andy Green <andy@warmcat.com>
Signed-off-by: John Keeping <john@keeping.me.uk>
This commit is contained in:
Andy Green 2018-06-13 10:02:00 +08:00 committed by John Keeping
parent 48f175083a
commit 7708859c4d

View File

@ -127,6 +127,8 @@ static void print_object(const unsigned char *sha1, char *path, const char *base
print_binary_buffer(buf, size);
else
print_text_buffer(basename, buf, size);
free(buf);
}
struct single_tree_ctx {