sigh, sizeof the correct variable so we can match ifname's > 4 bytes

This commit is contained in:
sam 2005-08-06 18:47:12 +00:00
parent 2269fa4b40
commit 653cdbcef0

View File

@ -170,7 +170,7 @@ main(int argc, char *argv[])
#else
snprintf(oid, sizeof(oid), "net.wlan.%d.%%parent", unit);
#endif
parentlen = sizeof(parentlen);
parentlen = sizeof(parent);
if (sysctlbyname(oid, parent, &parentlen, NULL, 0) >= 0 &&
strncmp(parent, ifname, parentlen) == 0)
break;