]> git.baikalelectronics.ru Git - kernel.git/commit
ext4: fixed potential NULL dereference in ext4_calculate_overhead()
authorVahram Martirosyan <vmartirosyan@gmail.com>
Wed, 28 Nov 2012 17:44:16 +0000 (12:44 -0500)
committerTheodore Ts'o <tytso@mit.edu>
Wed, 28 Nov 2012 17:44:16 +0000 (12:44 -0500)
commit5976f116b8b28af9855b12b143c987af05736fb7
tree33aa0c54b0ad7dd3aa6036f4a6351827275286f1
parentf7650355dd18badc2d18e20c63322ee2973aa66b
ext4: fixed potential NULL dereference in ext4_calculate_overhead()

The memset operation before check can cause a BUG if the memory
allocation failed.  Since we are using get_zeroed_age, there is no
need to use memset anyway.

Found by the Spruce system in cooperation with the KEDR Framework.

Signed-off-by: Vahram Martirosyan <vmartirosyan@linuxtesting.org>
Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
fs/ext4/super.c