Re: [PATCH 2/8] xfs: Fix open flag handling in open_by_handle code

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

 



>  	/* Put open permission in namei format. */

this coment is obsolete now.

>  	permflag = hreq->oflags;
> -	if ((permflag+1) & O_ACCMODE)
> -		permflag++;
> -	if (permflag & O_TRUNC)
> -		permflag |= 2;
> -
>  	if ((!(permflag & O_APPEND) || (permflag & O_TRUNC)) &&
> -	    (permflag & FMODE_WRITE) && IS_APPEND(inode)) {
> +	    (OPEN_FMODE(permflag) & FMODE_WRITE) && IS_APPEND(inode)) {

It would seem cleaner to still keep a loca fmode_t fmode variable
instead of using OPEN_FMODE multiple times.

_______________________________________________
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