From e66be025a8e310737dd4aa3c64ca3a96f164f1bb Mon Sep 17 00:00:00 2001 From: Thomas Bushnell Date: Mon, 18 Nov 1996 23:47:20 +0000 Subject: Fri Nov 15 14:43:44 1996 Thomas Bushnell, n/BSG * fshelp.h (fshelp_access): Uh, shift bits the right direction. Tue Nov 12 22:07:41 1996 Thomas Bushnell, n/BSG * fetch-root.c (fshelp_fetch_root): Name idvec members correctly. * fshelp.h: -> . Include . (fshelp_access): Declare `gotit'. --- libfshelp/ChangeLog | 12 ++++++++++++ libfshelp/fetch-root.c | 4 ++-- libfshelp/fshelp.h | 6 ++++-- 3 files changed, 18 insertions(+), 4 deletions(-) diff --git a/libfshelp/ChangeLog b/libfshelp/ChangeLog index f653a3b8..7223cba7 100644 --- a/libfshelp/ChangeLog +++ b/libfshelp/ChangeLog @@ -1,3 +1,15 @@ +Fri Nov 15 14:43:44 1996 Thomas Bushnell, n/BSG + + * fshelp.h (fshelp_access): Uh, shift bits the right direction. + +Tue Nov 12 22:07:41 1996 Thomas Bushnell, n/BSG + + * fetch-root.c (fshelp_fetch_root): Name idvec members correctly. + + * fshelp.h: -> . + Include . + (fshelp_access): Declare `gotit'. + Wed Nov 6 17:49:33 1996 Thomas Bushnell, n/BSG * fshelp.h (fshelp_fetch_root): Delete args `uids', `gids', diff --git a/libfshelp/fetch-root.c b/libfshelp/fetch-root.c index c0d30489..4e397d10 100644 --- a/libfshelp/fetch-root.c +++ b/libfshelp/fetch-root.c @@ -169,8 +169,8 @@ fshelp_fetch_root (struct transbox *box, void *cookie, /* Cancellation point XXX */ err = fsys_getroot (control, dotdot, MACH_MSG_TYPE_COPY_SEND, - user->uids->ids, user->uids->len, - user->gids->ids, user->gids->len, + user->uids->ids, user->uids->num, + user->gids->ids, user->gids->num, flags, retry, retryname, root); mutex_lock (box->lock); diff --git a/libfshelp/fshelp.h b/libfshelp/fshelp.h index 93ebd11f..3392006f 100644 --- a/libfshelp/fshelp.h +++ b/libfshelp/fshelp.h @@ -27,7 +27,8 @@ #include #include #include -#include +#include +#include #ifndef FSHELP_EI #define FSHELP_EI extern inline @@ -269,10 +270,11 @@ fshelp_isowner (struct stat *st, struct iouser *user) FSHELP_EI error_t fshelp_access (struct stat *st, int op, struct iouser *user) { + int gotit; if (idvec_contains (user->uids, 0)) gotit = 1; else if (user->uids->num == 0 && (st->st_mode & S_IUSEUNK)) - gotit = st->st_mode & (op << S_IUSEUNKSHIFT); + gotit = st->st_mode & (op << S_IUNKSHIFT); else if (!fshelp_isowner (st, user)) gotit = st->st_mode & op; else if (idvec_contains (user->gids, st->st_gid)) -- cgit v1.2.3