PERFORCE change 91432 for review
John Baldwin
jhb at FreeBSD.org
Thu Feb 9 10:09:02 PST 2006
http://perforce.freebsd.org/chv.cgi?CH=91432
Change 91432 by jhb at jhb_slimer on 2006/02/09 18:08:03
Use the single pfs_visible() call in pfs_getextattr() that des@
prefers.
Affected files ...
.. //depot/projects/smpng/sys/fs/pseudofs/pseudofs_vnops.c#41 edit
Differences ...
==== //depot/projects/smpng/sys/fs/pseudofs/pseudofs_vnops.c#41 (text+ko) ====
@@ -287,15 +287,6 @@
PFS_TRACE((pn->pn_name));
-#if 0
- /* Umm, no need to call this twice. */
- if (!pfs_visible(curthread, pn, pvd->pvd_pid))
- PFS_RETURN (ENOENT);
-#endif
-
- if (pn->pn_getextattr == NULL)
- PFS_RETURN (EOPNOTSUPP);
-
/*
* This is necessary because either process' privileges may
* have changed since the open() call.
@@ -303,6 +294,12 @@
if (!pfs_visible(curthread, pn, pvd->pvd_pid, &proc))
PFS_RETURN (EIO);
+ if (pn->pn_getextattr == NULL) {
+ if (proc != NULL)
+ PROC_UNLOCK(proc);
+ PFS_RETURN (EOPNOTSUPP);
+ }
+
if (proc != NULL) {
_PHOLD(proc);
PROC_UNLOCK(proc);
More information about the p4-projects
mailing list