Re: [PATCH 1/4 linux-next] xfs: use swap() in xfs_dir2_leafn_rebalance()

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

 



On Mon, May 18, 2015 at 07:13:48PM +0200, Fabian Frederick wrote:
>  	 * If the block order is wrong, swap the arguments.
>  	 */
> -	if ((swap = xfs_dir2_leafn_order(dp, blk1->bp, blk2->bp))) {
> -		xfs_da_state_blk_t	*tmp;	/* temp for block swap */
> +	swap = xfs_dir2_leafn_order(dp, blk1->bp, blk2->bp);
> +	if (swap)
> +		swap(blk1, blk2);

Egads...  Have you even read what you'd written?  Yes, sure, preprocessor
will do the right thing, but it's a very noticable annoyance for somebody
reading that.  Rename the bleeding flag, please.

_______________________________________________
xfs mailing list
xfs@xxxxxxxxxxx
http://oss.sgi.com/mailman/listinfo/xfs




[Index of Archives]     [Linux XFS Devel]     [Linux Filesystem Development]     [Filesystem Testing]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux