adfs: return correct return values
Fix the wrong values returned by various functions such as EIO and ENOMEM. Signed-off-by: Sanidhya Kashyap <sanidhya.gatech@gmail.com> Cc: Fabian Frederick <fabf@skynet.be> Cc: Joe Perches <joe@perches.com> Cc: Taesoo kim <taesoo@gatech.edu> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
This commit is contained in:
parent
9d796e6623
commit
b796410630
2 changed files with 16 additions and 5 deletions
|
@ -61,6 +61,7 @@ adfs_fplus_read(struct super_block *sb, unsigned int id, unsigned int sz, struct
|
|||
kcalloc(size, sizeof(struct buffer_head *),
|
||||
GFP_KERNEL);
|
||||
if (!bh_fplus) {
|
||||
ret = -ENOMEM;
|
||||
adfs_error(sb, "not enough memory for"
|
||||
" dir object %X (%d blocks)", id, size);
|
||||
goto out;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue