mirror of
https://git.FreeBSD.org/src.git
synced 2025-01-16 15:11:52 +00:00
Fix few missed accmode changes in coda.
Approved by: rwatson (mentor)
This commit is contained in:
parent
8481e37b53
commit
ea49f15447
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=184595
@ -102,7 +102,7 @@ struct cnode {
|
||||
char *c_symlink; /* pointer to symbolic link */
|
||||
u_short c_symlen; /* length of symbolic link */
|
||||
uid_t c_cached_uid; /* cached uid */
|
||||
mode_t c_cached_mode; /* cached access mode */
|
||||
accmode_t c_cached_mode; /* cached access mode */
|
||||
struct cnode *c_next; /* links if on FreeBSD machine */
|
||||
};
|
||||
#define VTOC(vp) ((struct cnode *)(vp)->v_data)
|
||||
|
@ -195,7 +195,7 @@ coda_acccache_purge(struct mount *mnt)
|
||||
CODADEBUG(CODA_FLUSH, myprintf(("acccache "
|
||||
"purge fid %s uid %d mode 0x%x\n",
|
||||
coda_f2s(&cp->c_fid), cp->c_cached_uid,
|
||||
cp->c_cached_mode)););
|
||||
(int)cp->c_cached_mode)););
|
||||
cp->c_flags &= ~C_ACCCACHE;
|
||||
}
|
||||
}
|
||||
@ -223,7 +223,7 @@ coda_acccache_purgeuser(struct mount *mnt, uid_t uid)
|
||||
CODADEBUG(CODA_PURGEUSER, myprintf((
|
||||
"acccache purgeuser fid %s uid %d mode "
|
||||
"0x%x\n", coda_f2s(&cp->c_fid),
|
||||
cp->c_cached_uid, cp->c_cached_mode)););
|
||||
cp->c_cached_uid, (int)cp->c_cached_mode)););
|
||||
cp->c_flags &= ~C_ACCCACHE;
|
||||
}
|
||||
}
|
||||
|
@ -347,7 +347,7 @@ venus_setattr(void *mdp, CodaFid *fid, struct vattr *vap, struct ucred *cred)
|
||||
}
|
||||
|
||||
int
|
||||
venus_access(void *mdp, CodaFid *fid, int mode, struct ucred *cred,
|
||||
venus_access(void *mdp, CodaFid *fid, accmode_t accmode, struct ucred *cred,
|
||||
struct proc *p)
|
||||
{
|
||||
DECL_NO_OUT(coda_access); /* sets Isize & Osize */
|
||||
@ -362,8 +362,10 @@ venus_access(void *mdp, CodaFid *fid, int mode, struct ucred *cred,
|
||||
/*
|
||||
* NOTE: FreeBSD and Venus internals use the "data" in the low 3
|
||||
* bits. Hence, the conversion.
|
||||
*
|
||||
* XXX: We cast accmode_t variable into an int.
|
||||
*/
|
||||
inp->flags = mode>>6;
|
||||
inp->flags = (int)accmode>>6;
|
||||
|
||||
error = coda_call(mdp, Isize, &Osize, (char *)inp);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user