sysctlbyname takes a size_t as its 5th argument, not a pointer.

However, since NULL was used, and this is C++, this error went
undetected until g++ 3.3 somehow managed to whine about it.

Reported by: obrien
This commit is contained in:
Warner Losh 2003-05-02 17:38:08 +00:00
parent eadb8f358b
commit 79f92e2597
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=114541

View File

@ -708,7 +708,7 @@ check_devd_enabled()
size_t len;
len = sizeof(val);
if (sysctlbyname(SYSCTL, &val, &len, NULL, NULL) != 0)
if (sysctlbyname(SYSCTL, &val, &len, NULL, 0) != 0)
errx(1, "devctl sysctl missing from kernel!");
if (val) {
warnx("Setting " SYSCTL " to 0");