summaryrefslogtreecommitdiffstats
path: root/sys/kern/uipc_usrreq.c
diff options
context:
space:
mode:
authorphk <phk@FreeBSD.org>2004-12-01 09:22:26 +0000
committerphk <phk@FreeBSD.org>2004-12-01 09:22:26 +0000
commit9b4cd725f10562da76638ddca6a4eebdb665764c (patch)
tree910e0e555c0af2a7c0dccefe30d34dc9be83c238 /sys/kern/uipc_usrreq.c
parent31e045eaae3af67634f7d76dd3927307359e3cd6 (diff)
downloadFreeBSD-src-9b4cd725f10562da76638ddca6a4eebdb665764c.zip
FreeBSD-src-9b4cd725f10562da76638ddca6a4eebdb665764c.tar.gz
"nfiles" is a bad name for a global variable. Call it "openfiles" instead
as this is more correct and matches the sysctl variable.
Diffstat (limited to 'sys/kern/uipc_usrreq.c')
-rw-r--r--sys/kern/uipc_usrreq.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/kern/uipc_usrreq.c b/sys/kern/uipc_usrreq.c
index af93e2e..be4bcb2 100644
--- a/sys/kern/uipc_usrreq.c
+++ b/sys/kern/uipc_usrreq.c
@@ -1664,11 +1664,11 @@ unp_gc()
* 91/09/19, bsy@cs.cmu.edu
*/
again:
- nfiles_snap = nfiles + nfiles_slack; /* some slack */
+ nfiles_snap = openfiles + nfiles_slack; /* some slack */
extra_ref = malloc(nfiles_snap * sizeof(struct file *), M_TEMP,
M_WAITOK);
sx_slock(&filelist_lock);
- if (nfiles_snap < nfiles) {
+ if (nfiles_snap < openfiles) {
sx_sunlock(&filelist_lock);
free(extra_ref, M_TEMP);
nfiles_slack += 20;
OpenPOWER on IntegriCloud