Home
last modified time | relevance | path

Searched hist:"6 f8ff537" (Results 1 – 1 of 1) sorted by relevance

/openbmc/linux/fs/ext4/
H A Dextents.c6f8ff537 Wed Oct 26 03:38:59 CDT 2011 Curt Wohlgemuth <curtw@google.com> ext4: handle NULL p_ext in ext4_ext_next_allocated_block()

In ext4_ext_next_allocated_block(), the path[depth] might
have a p_ext that is NULL -- see ext4_ext_binsearch(). In
such a case, dereferencing it will crash the machine.

This patch checks for p_ext == NULL in
ext4_ext_next_allocated_block() before dereferencinging it.

Tested using a hand-crafted an inode with eh_entries == 0 in
an extent block, verified that running FIEMAP on it crashes
without this patch, works fine with it.

Signed-off-by: Curt Wohlgemuth <curtw@google.com>
Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>