diff options
author | eivind <eivind@FreeBSD.org> | 1999-12-15 23:02:35 +0000 |
---|---|---|
committer | eivind <eivind@FreeBSD.org> | 1999-12-15 23:02:35 +0000 |
commit | 87724eb67358c0993676ad3dfe9091e192a653f4 (patch) | |
tree | c4e987197c199433e822f5a66858564ad5ccd4dd /sys/i386/ibcs2 | |
parent | 529bc073c0dba1aaccc98818ee299b79a111afab (diff) | |
download | FreeBSD-src-87724eb67358c0993676ad3dfe9091e192a653f4.zip FreeBSD-src-87724eb67358c0993676ad3dfe9091e192a653f4.tar.gz |
Introduce NDFREE (and remove VOP_ABORTOP)
Diffstat (limited to 'sys/i386/ibcs2')
-rw-r--r-- | sys/i386/ibcs2/ibcs2_stat.c | 5 | ||||
-rw-r--r-- | sys/i386/ibcs2/ibcs2_util.c | 9 | ||||
-rw-r--r-- | sys/i386/ibcs2/ibcs2_xenix.c | 3 | ||||
-rw-r--r-- | sys/i386/ibcs2/imgact_coff.c | 2 |
4 files changed, 17 insertions, 2 deletions
diff --git a/sys/i386/ibcs2/ibcs2_stat.c b/sys/i386/ibcs2/ibcs2_stat.c index 36990c3..863e6e0 100644 --- a/sys/i386/ibcs2/ibcs2_stat.c +++ b/sys/i386/ibcs2/ibcs2_stat.c @@ -24,6 +24,8 @@ * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * $FreeBSD$ */ #include <sys/param.h> @@ -45,6 +47,8 @@ #include <i386/ibcs2/ibcs2_util.h> #include <i386/ibcs2/ibcs2_utsname.h> +#include <vm/vm_zone.h> + static void bsd_stat2ibcs_stat __P((struct stat *, struct ibcs2_stat *)); static int cvt_statfs __P((struct statfs *, caddr_t, int)); @@ -106,6 +110,7 @@ ibcs2_statfs(p, uap) NDINIT(&nd, LOOKUP, FOLLOW, UIO_USERSPACE, SCARG(uap, path), p); if ((error = namei(&nd)) != 0) return (error); + NDFREE(&nd, NDF_ONLY_PNBUF); mp = nd.ni_vp->v_mount; sp = &mp->mnt_stat; vrele(nd.ni_vp); diff --git a/sys/i386/ibcs2/ibcs2_util.c b/sys/i386/ibcs2/ibcs2_util.c index 2ae6f2d..e90b3d9 100644 --- a/sys/i386/ibcs2/ibcs2_util.c +++ b/sys/i386/ibcs2/ibcs2_util.c @@ -27,6 +27,7 @@ * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * * from: svr4_util.c,v 1.5 1995/01/22 23:44:50 christos Exp + * $FreeBSD$ */ #include <sys/param.h> @@ -37,6 +38,8 @@ #include <i386/ibcs2/ibcs2_util.h> +#include <vm/vm_zone.h> + const char ibcs2_emul_path[] = "/compat/ibcs2"; /* @@ -133,6 +136,7 @@ ibcs2_emul_find(p, sgp, prefix, path, pbuf, cflag) if ((error = namei(&ndroot)) != 0) { /* Cannot happen! */ free(buf, M_TEMP); + NDFREE(&nd, NDF_ONLY_PNBUF); vrele(nd.ni_vp); return error; } @@ -164,8 +168,11 @@ ibcs2_emul_find(p, sgp, prefix, path, pbuf, cflag) done: + NDFREE(&nd, NDF_ONLY_PNBUF); vrele(nd.ni_vp); - if (!cflag) + if (!cflag) { + NDFREE(&ndroot, NDF_ONLY_PNBUF); vrele(ndroot.ni_vp); + } return error; } diff --git a/sys/i386/ibcs2/ibcs2_xenix.c b/sys/i386/ibcs2/ibcs2_xenix.c index 67af2fc..bf77113 100644 --- a/sys/i386/ibcs2/ibcs2_xenix.c +++ b/sys/i386/ibcs2/ibcs2_xenix.c @@ -49,6 +49,8 @@ #include <i386/ibcs2/ibcs2_xenix.h> #include <i386/ibcs2/ibcs2_xenix_syscall.h> +#include <vm/vm_zone.h> + extern struct sysent xenix_sysent[]; int @@ -218,6 +220,7 @@ xenix_eaccess(struct proc *p, struct xenix_eaccess_args *uap) if ((flags & VWRITE) == 0 || (error = vn_writechk(vp)) == 0) error = VOP_ACCESS(vp, flags, cred, p); } + NDFREE(&nd, NDF_ONLY_PNBUF); vput(vp); return error; } diff --git a/sys/i386/ibcs2/imgact_coff.c b/sys/i386/ibcs2/imgact_coff.c index 526ff66..1ada323 100644 --- a/sys/i386/ibcs2/imgact_coff.c +++ b/sys/i386/ibcs2/imgact_coff.c @@ -279,8 +279,8 @@ coff_load_file(struct proc *p, char *name) fail: VOP_UNLOCK(vp, 0, p); unlocked_fail: + NDFREE(&nd, NDF_ONLY_PNBUF); vrele(nd.ni_vp); - zfree(namei_zone, nd.ni_cnd.cn_pnbuf); return error; } |