summaryrefslogtreecommitdiffstats
path: root/sys/netsmb
diff options
context:
space:
mode:
authortruckman <truckman@FreeBSD.org>2002-07-28 19:59:31 +0000
committertruckman <truckman@FreeBSD.org>2002-07-28 19:59:31 +0000
commitb1555a27432152cc7817d0c592bbcebf95fdfd19 (patch)
tree6dda6f0898c9f15fca929e63e72b3882862e67e1 /sys/netsmb
parent5bd1876975f34760da2eea4bfce9c738127d36ca (diff)
downloadFreeBSD-src-b1555a27432152cc7817d0c592bbcebf95fdfd19.zip
FreeBSD-src-b1555a27432152cc7817d0c592bbcebf95fdfd19.tar.gz
Wire the sysctl output buffer before grabbing any locks to prevent
SYSCTL_OUT() from blocking while locks are held. This should only be done when it would be inconvenient to make a temporary copy of the data and defer calling SYSCTL_OUT() until after the locks are released.
Diffstat (limited to 'sys/netsmb')
-rw-r--r--sys/netsmb/smb_conn.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/sys/netsmb/smb_conn.c b/sys/netsmb/smb_conn.c
index 657c469..9c52571 100644
--- a/sys/netsmb/smb_conn.c
+++ b/sys/netsmb/smb_conn.c
@@ -834,6 +834,7 @@ smb_sysctl_treedump(SYSCTL_HANDLER_ARGS)
int error, itype;
smb_makescred(&scred, td, td->td_ucred);
+ sysctl_wire_old_buffer(req, 0);
error = smb_sm_lockvclist(LK_SHARED, td);
if (error)
return error;
OpenPOWER on IntegriCloud