summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorderaadt <deraadt@openbsd.org>2004-06-12 17:53:18 +0000
committerderaadt <deraadt@openbsd.org>2004-06-12 17:53:18 +0000
commit3f014af85f8fd7d6a9a12cdcafdf65804876da2d (patch)
tree16b0372bedb92f0b713820c4a8436bed8c3f9eed
parentmake M-x gid try to guess the symbol name to look up by looking at the (diff)
downloadwireguard-openbsd-3f014af85f8fd7d6a9a12cdcafdf65804876da2d.tar.xz
wireguard-openbsd-3f014af85f8fd7d6a9a12cdcafdf65804876da2d.zip
fix ncpu vs ncpus glitch, spotted by Sven Dehmlow
-rw-r--r--sys/miscfs/kernfs/kernfs_vnops.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/sys/miscfs/kernfs/kernfs_vnops.c b/sys/miscfs/kernfs/kernfs_vnops.c
index 0846a3e3a27..9102b638b18 100644
--- a/sys/miscfs/kernfs/kernfs_vnops.c
+++ b/sys/miscfs/kernfs/kernfs_vnops.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: kernfs_vnops.c,v 1.38 2004/05/20 18:32:37 tedu Exp $ */
+/* $OpenBSD: kernfs_vnops.c,v 1.39 2004/06/12 17:53:18 deraadt Exp $ */
/* $NetBSD: kernfs_vnops.c,v 1.43 1996/03/16 23:52:47 christos Exp $ */
/*
@@ -69,7 +69,7 @@
static int byteorder = BYTE_ORDER;
static int posix = _POSIX_VERSION;
static int osrev = OpenBSD;
-static int ncpu = 1; /* XXX */
+extern int ncpus;
extern char machine[], cpu_model[];
#ifdef IPSEC
@@ -92,7 +92,7 @@ const struct kern_target kern_targets[] = {
{ DT_REG, N("machine"), machine, KTT_STRING, VREG, READ_MODE },
{ DT_REG, N("model"), cpu_model, KTT_STRING, VREG, READ_MODE },
{ DT_REG, N("msgbuf"), 0, KTT_MSGBUF, VREG, READ_MODE },
- { DT_REG, N("ncpu"), &ncpu, KTT_INT, VREG, READ_MODE },
+ { DT_REG, N("ncpu"), &ncpus, KTT_INT, VREG, READ_MODE },
{ DT_REG, N("ostype"), (void*)&ostype,KTT_STRING, VREG, READ_MODE },
{ DT_REG, N("osrelease"), (void*)&osrelease,KTT_STRING,VREG, READ_MODE },
{ DT_REG, N("osrev"), &osrev, KTT_INT, VREG, READ_MODE },