From: Richard Genoud Date: Tue, 3 Nov 2020 11:11:07 +0000 (+0100) Subject: fs/squashfs: sqfs_read_inode_table: fix dangling pointer X-Git-Url: http://git.dujemihanovic.xyz/img/static/git-logo.png?a=commitdiff_plain;h=4c83d2755776d4dd5e15a930d48db1082fc0d1cc;p=u-boot.git fs/squashfs: sqfs_read_inode_table: fix dangling pointer inode_table should not be left dangling as it may be freed in sqfs_opendir Signed-off-by: Richard Genoud --- diff --git a/fs/squashfs/sqfs.c b/fs/squashfs/sqfs.c index 1714306e74..72181f3833 100644 --- a/fs/squashfs/sqfs.c +++ b/fs/squashfs/sqfs.c @@ -731,6 +731,7 @@ static int sqfs_read_inode_table(unsigned char **inode_table) src_table, src_len); if (ret) { free(*inode_table); + *inode_table = NULL; goto free_itb; }