1
mirror of https://github.com/rapid7/metasploit-payloads synced 2025-03-12 12:14:29 +01:00

Fix small indexing issue resulting in a crash

This commit is contained in:
OJ 2014-01-23 10:19:33 +10:00
parent da194e07b4
commit 3ec5aaca3f

@ -316,7 +316,7 @@ DWORD wmi_query(LPCWSTR lpwRoot, LPWSTR lpwQuery, Packet* response)
}
dprintf("[WMI] Bounds: %u to %u", lBound, uBound);
LONG fieldCount = uBound - lBound - SYSTEM_FIELD_COUNT;
LONG fieldCount = uBound - lBound - SYSTEM_FIELD_COUNT - 1;
dprintf("[WMI] Query results in %u fields", fieldCount);
fields = (VARIANT**)malloc(fieldCount * sizeof(VARIANT**));