linux/fs/hfs
Alexey Khoroshilov 9509f17851 hfs: add error checking for hfs_find_init()
hfs_find_init() may fail with ENOMEM, but there are places, where the
returned value is not checked.  The consequences can be very unpleasant,
e.g.  kfree uninitialized pointer and inappropriate mutex unlocking.

The patch adds checks for errors in hfs_find_init().

Found by Linux Driver Verification project (linuxtesting.org).

Signed-off-by: Alexey Khoroshilov <khoroshilov@ispras.ru>
Reviewed-by: Vyacheslav Dubeyko <slava@dubeyko.com>
Cc: Hin-Tak Leung <htl10@users.sourceforge.net>
Cc: Al Viro <viro@zeniv.linux.org.uk>
Cc: Artem Bityutskiy <artem.bityutskiy@linux.intel.com>
Cc: Christoph Hellwig <hch@lst.de>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2013-04-30 17:04:05 -07:00
..
Kconfig fs/hfs: remove depends on CONFIG_EXPERIMENTAL 2013-01-21 14:39:05 -08:00
Makefile
attr.c
bfind.c
bitmap.c
bnode.c
brec.c
btree.c hfs: fix hfs_find_init() sb->ext_tree NULL ptr oops 2011-11-02 16:06:59 -07:00
btree.h
catalog.c hfs: add error checking for hfs_find_init() 2013-04-30 17:04:05 -07:00
dir.c hfs: add error checking for hfs_find_init() 2013-04-30 17:04:05 -07:00
extent.c hfs: add error checking for hfs_find_init() 2013-04-30 17:04:05 -07:00
hfs.h
hfs_fs.h hfs: add error checking for hfs_find_init() 2013-04-30 17:04:05 -07:00
inode.c hfs: add error checking for hfs_find_init() 2013-04-30 17:04:05 -07:00
mdb.c hfs: nuke write_super from comments 2012-08-04 12:15:38 +04:00
part_tbl.c
string.c
super.c hfs: add error checking for hfs_find_init() 2013-04-30 17:04:05 -07:00
sysdep.c stop passing nameidata * to ->d_revalidate() 2012-07-14 16:34:14 +04:00
trans.c hfs: add sanity check for file name length 2011-11-15 14:29:42 -02:00