Date: Thu, 9 Feb 2006 18:09:00 GMT From: John Baldwin <jhb@FreeBSD.org> To: Perforce Change Reviews <perforce@freebsd.org> Subject: PERFORCE change 91432 for review Message-ID: <200602091809.k19I90E1025269@repoman.freebsd.org>
next in thread | raw e-mail | index | archive | help
http://perforce.freebsd.org/chv.cgi?CH=91432 Change 91432 by jhb@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);
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200602091809.k19I90E1025269>