Darrick J. Wong 96a3aefb8f xfs: don't crash if reading a directory results in an unexpected hole
In xfs_dir3_data_read, we can encounter the situation where err == 0 and
*bpp == NULL if the given bno offset happens to be a hole; this leads to
a crash if we try to set the buffer type after the _da_read_buf call.
Holes can happen due to corrupt or malicious entries in the bmbt data,
so be a little more careful when we're handling buffers.

Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com>
Reviewed-by: Dave Chinner <dchinner@redhat.com>
Signed-off-by: Dave Chinner <david@fromorbit.com>
2016-12-05 12:37:47 +11:00
..
2016-04-06 09:47:01 +10:00
2016-04-06 09:47:01 +10:00
2016-10-04 18:06:40 -07:00
2016-10-04 11:05:44 -07:00
2016-10-13 20:28:22 -07:00
2016-06-01 17:38:15 +10:00
2016-10-20 15:42:30 +11:00
2016-10-20 15:54:45 +11:00