From 8425294fee2c566c56940716cb05dbfa3f93b589 Mon Sep 17 00:00:00 2001 From: Pedro Martelletto Date: Tue, 27 Jan 2015 21:28:23 +0100 Subject: [PATCH] Don't leak buffers in wapbl_doio(). Mark the buffer with B_INVAL so it is disposed of by brelse(). OK patrick@. --- sys/kern/vfs_wapbl.c | 1 + 1 file changed, 1 insertion(+) diff --git a/sys/kern/vfs_wapbl.c b/sys/kern/vfs_wapbl.c index b40cb7ff3a8..a691dd8827e 100644 --- a/sys/kern/vfs_wapbl.c +++ b/sys/kern/vfs_wapbl.c @@ -777,6 +777,7 @@ wapbl_doio(void *data, size_t len, struct vnode *devvp, daddr_t pbn, int flags) s = splbio(); bp->b_vp = NULL; + bp->b_flags |= B_INVAL; brelse(bp); splx(s);