fs/squashfs: sqfs_read: fix another memory leak

data_buffer was allocated in a loop and freed only once.

Signed-off-by: Richard Genoud <richard.genoud@posteo.net>
This commit is contained in:
Richard Genoud 2020-11-03 12:11:14 +01:00 committed by Tom Rini
parent 7ce9745cbe
commit 555459e793

View File

@ -1459,6 +1459,8 @@ int sqfs_read(const char *filename, void *buf, loff_t offset, loff_t len,
}
data_offset += table_size;
free(data_buffer);
data_buffer = NULL;
}
free(finfo.blk_sizes);