Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit e6022603 authored by Andrew Morton's avatar Andrew Morton Committed by Linus Torvalds
Browse files

[PATCH] ext3_clear_inode(): avoid kfree(NULL)



Steven Rostedt <rostedt@goodmis.org> points out that `rsv' here is usually
NULL, so we should avoid calling kfree().

Also, fix up some nearby whitespace damage.

Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
parent 304c4c84
Loading
Loading
Loading
Loading
+12 −11
Original line number Diff line number Diff line
@@ -512,6 +512,7 @@ static void ext3_clear_inode(struct inode *inode)
#endif
	ext3_discard_reservation(inode);
	EXT3_I(inode)->i_block_alloc_info = NULL;
	if (unlikely(rsv))
		kfree(rsv);
}