ext4: fix error return from ext4_ext_handle_uninitialized_extents()
authorEric Whitney <enwlinux@gmail.com>
Wed, 19 Feb 2014 23:52:39 +0000 (18:52 -0500)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sun, 27 Apr 2014 00:15:35 +0000 (17:15 -0700)
commitcbe099ed98247f60f18a828edd1b0bd07560b460
tree59e3ab9fc7258cf0f88f51e1a45671fb9cae19ab
parent19fc37ed7b9e8cdde28597adb9714d6f863985b4
ext4: fix error return from ext4_ext_handle_uninitialized_extents()

commit ce37c42919608e96ade3748fe23c3062a0a966c5 upstream.

Commit 3779473246 breaks the return of error codes from
ext4_ext_handle_uninitialized_extents() in ext4_ext_map_blocks().  A
portion of the patch assigns that function's signed integer return
value to an unsigned int.  Consequently, negatively valued error codes
are lost and can be treated as a bogus allocated block count.

Signed-off-by: Eric Whitney <enwlinux@gmail.com>
Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
fs/ext4/extents.c