[PATCH] xfs_repair: check for null single-block dir buffer pointer in phase6

Eric Sandeen sandeen at sandeen.net
Sun Jul 26 17:52:28 CDT 2009


Christoph Hellwig wrote:
> On Fri, Jul 24, 2009 at 09:34:08AM -0500, Eric Sandeen wrote:
>> @@ -2524,7 +2525,7 @@ longform_dir2_entry_check(xfs_mount_t	*mp,
>>  
>>  	if (!dotdot_update) {
>>  		/* check btree and freespace */
>> -		if (isblock) {
>> +		if (isblock && bplist[0]) {
>>  			xfs_dir2_block_tail_t	*btp;
>>  			xfs_dir2_leaf_entry_t	*blp;
> 
> This doesn't look quite correct to me.  Now we falls through to the
> final else statement when bplist[0] is zeroed.
> 

Oh, ugh, you're right.  Will fix that up, thanks.

-Eric




More information about the xfs mailing list