summaryrefslogtreecommitdiff
path: root/sys/uvm/uvm_swap.c
diff options
context:
space:
mode:
authorArtur Grabowski <art@cvs.openbsd.org>2001-07-18 14:28:02 +0000
committerArtur Grabowski <art@cvs.openbsd.org>2001-07-18 14:28:02 +0000
commit591d15cdd8d0d5cc271b5e17ccc8f87b8c294ec6 (patch)
treeec1a08499be1580969a4d6f455dda498486513b7 /sys/uvm/uvm_swap.c
parentcdc997fc03b436e277b896bb4db10521089ad9ff (diff)
minor sync to NetBSD, nothing changed.
Diffstat (limited to 'sys/uvm/uvm_swap.c')
-rw-r--r--sys/uvm/uvm_swap.c10
1 files changed, 6 insertions, 4 deletions
diff --git a/sys/uvm/uvm_swap.c b/sys/uvm/uvm_swap.c
index 76c294d06e2..d57013300d2 100644
--- a/sys/uvm/uvm_swap.c
+++ b/sys/uvm/uvm_swap.c
@@ -1,5 +1,5 @@
-/* $OpenBSD: uvm_swap.c,v 1.28 2001/07/05 10:00:49 art Exp $ */
-/* $NetBSD: uvm_swap.c,v 1.28 1999/07/22 22:58:39 thorpej Exp $ */
+/* $OpenBSD: uvm_swap.c,v 1.29 2001/07/18 14:28:01 art Exp $ */
+/* $NetBSD: uvm_swap.c,v 1.29 1999/10/16 23:53:29 wrstuden Exp $ */
/*
* Copyright (c) 1995, 1996, 1997 Matthew R. Green
@@ -1203,8 +1203,9 @@ bad:
/*
* failure: close device if necessary and return error.
*/
- if (vp != rootvp)
+ if (vp != rootvp) {
(void)VOP_CLOSE(vp, FREAD|FWRITE, p->p_ucred, p);
+ }
return (error);
}
@@ -1260,8 +1261,9 @@ swap_off(p, sdp)
extent_destroy(sdp->swd_ex);
free(name, M_VMSWAP);
free((caddr_t)sdp->swd_ex, M_VMSWAP);
- if (sdp->swp_vp != rootvp)
+ if (sdp->swp_vp != rootvp) {
(void) VOP_CLOSE(sdp->swd_vp, FREAD|FWRITE, p->p_ucred, p);
+ }
if (sdp->swd_vp)
vrele(sdp->swd_vp);
free((caddr_t)sdp, M_VMSWAP);