diff options
| author | Eivind Eklund <eivind@FreeBSD.org> | 1999-12-15 23:02:35 +0000 |
|---|---|---|
| committer | Eivind Eklund <eivind@FreeBSD.org> | 1999-12-15 23:02:35 +0000 |
| commit | 762e6b856c64ee48f286a7f0b45d0067e556b252 (patch) | |
| tree | cf4d02d65f6e44871147fef3ce69de82368a30e5 /sys/compat/linux/linux_util.c | |
| parent | 0b994c2e87a9de9d7eb48152a943ca4c21a4f788 (diff) | |
Notes
Diffstat (limited to 'sys/compat/linux/linux_util.c')
| -rw-r--r-- | sys/compat/linux/linux_util.c | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/sys/compat/linux/linux_util.c b/sys/compat/linux/linux_util.c index 7c87174089a9..0864ae7caac8 100644 --- a/sys/compat/linux/linux_util.c +++ b/sys/compat/linux/linux_util.c @@ -39,6 +39,8 @@ #include <i386/linux/linux_util.h> +#include <vm/vm_zone.h> + const char linux_emul_path[] = "/compat/linux"; /* @@ -135,6 +137,7 @@ linux_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,13 +167,18 @@ linux_emul_find(p, sgp, prefix, path, pbuf, cflag) free(buf, M_TEMP); } + NDFREE(&nd, NDF_ONLY_PNBUF); vrele(nd.ni_vp); - if (!cflag) + if (!cflag) { + NDFREE(&ndroot, NDF_ONLY_PNBUF); vrele(ndroot.ni_vp); + } return error; bad: + NDFREE(&ndroot, NDF_ONLY_PNBUF); vrele(ndroot.ni_vp); + NDFREE(&nd, NDF_ONLY_PNBUF); vrele(nd.ni_vp); free(buf, M_TEMP); return error; |
