diff options
author | Richard Genoud <richard.genoud@posteo.net> | 2020-11-03 12:11:07 +0100 |
---|---|---|
committer | Jaehoon Chung <jh80.chung@samsung.com> | 2021-01-05 16:06:47 +0900 |
commit | 21cd23035c057224496903b42ac596c0bc7ad7d9 (patch) | |
tree | 3b3a5e5d791318705dd1a232d9e53c5c1d593100 /fs | |
parent | e4662562fb01567f6fb0a1893027b16ca682f52e (diff) | |
download | u-boot-21cd23035c057224496903b42ac596c0bc7ad7d9.tar.gz u-boot-21cd23035c057224496903b42ac596c0bc7ad7d9.tar.bz2 u-boot-21cd23035c057224496903b42ac596c0bc7ad7d9.zip |
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 <richard.genoud@posteo.net>
[jh80.chung: cherry picked from mainline commit 4c83d2755776d4dd5e15a930d48db1082fc0d1cc]
Signed-off-by: Jaehoon Chung <jh80.chung@samsung.com>
Change-Id: I0d63396f7885f68140e78623df8e06b8b00049ac
Diffstat (limited to 'fs')
-rw-r--r-- | fs/squashfs/sqfs.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/fs/squashfs/sqfs.c b/fs/squashfs/sqfs.c index 6e7140212c..620a6adaed 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; } |