Fixed wrong length argument in getInterfacePhysicalByName.

This commit is contained in:
Alexandre Julliard 2003-05-21 18:26:00 +00:00
parent bb993e0127
commit b168f12a48
1 changed files with 1 additions and 1 deletions

View File

@ -682,7 +682,7 @@ DWORD getInterfacePhysicalByName(const char *name, PDWORD len, PBYTE addr,
if (!name || !len || !addr || !type) if (!name || !len || !addr || !type)
return ERROR_INVALID_PARAMETER; return ERROR_INVALID_PARAMETER;
if (sysctl(mib, 6, NULL, &len, NULL, 0) < 0) if (sysctl(mib, 6, NULL, &mibLen, NULL, 0) < 0)
return ERROR_NO_MORE_FILES; return ERROR_NO_MORE_FILES;
buf = (u_char *)malloc(mibLen); buf = (u_char *)malloc(mibLen);