Re: [PATCH 3/5] xfs: factor free block index lookup from xfs_dir2_node_addname_int()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, Aug 29, 2019 at 01:10:13AM -0700, Christoph Hellwig wrote:
> On Thu, Aug 29, 2019 at 04:30:40PM +1000, Dave Chinner wrote:
> > +	/*
> > +	 * Now we know if we must allocate blocks, so if we are checking whether
> > +	 * we can insert without allocation then we can return now.
> > +	 */
> > +	if (args->op_flags & XFS_DA_OP_JUSTCHECK) {
> > +		if (dbno != -1)
> > +			return 0;
> > +		return -ENOSPC;
> > +	}
> 
> Nit: I'd invert the check to rturn -ENOSPC in the branch if dbno is
> -1 to make the flow a littler easier.

Fixed.

-Dave.

-- 
Dave Chinner
david@xxxxxxxxxxxxx



[Index of Archives]     [XFS Filesystem Development (older mail)]     [Linux Filesystem Development]     [Linux Audio Users]     [Yosemite Trails]     [Linux Kernel]     [Linux RAID]     [Linux SCSI]


  Powered by Linux