summaryrefslogtreecommitdiff
path: root/sys/xfs/xfs_common-bsd.c
diff options
context:
space:
mode:
authorTed Unangst <tedu@cvs.openbsd.org>2003-08-15 20:32:22 +0000
committerTed Unangst <tedu@cvs.openbsd.org>2003-08-15 20:32:22 +0000
commita1ee01486d4d2da0dce2fd97a58ca548a402d598 (patch)
treeeb06f4625b973fc701bb62d6902e4f1eb40bb4f2 /sys/xfs/xfs_common-bsd.c
parent1a3299929d48eae52404e0b75267c111d07d2af4 (diff)
change arguments to suser. suser now takes the process, and a flags
argument. old cred only calls user suser_ucred. this will allow future work to more flexibly implement the idea of a root process. looks like something i saw in freebsd, but a little different. use of suser_ucred vs suser in file system code should be looked at again, for the moment semantics remain unchanged. review and input from art@ testing and further review miod@
Diffstat (limited to 'sys/xfs/xfs_common-bsd.c')
-rw-r--r--sys/xfs/xfs_common-bsd.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/sys/xfs/xfs_common-bsd.c b/sys/xfs/xfs_common-bsd.c
index eac6fca8dd1..454df61fbd7 100644
--- a/sys/xfs/xfs_common-bsd.c
+++ b/sys/xfs/xfs_common-bsd.c
@@ -74,7 +74,11 @@ int
xfs_suser(d_thread_t *p)
{
#if defined(HAVE_TWO_ARGUMENT_SUSER)
+#ifdef __OpenBSD__
+ return suser (p, SUSER_NOACCT);
+#else
return suser (xfs_proc_to_cred(p), NULL);
+#endif
#else
return suser (p);
#endif