fix refactoring issues

This commit is contained in:
sina 2026-05-31 16:38:21 +02:00
parent 6bcd4a3b10
commit eeeff45f70
3 changed files with 9 additions and 9 deletions

View file

@ -1354,12 +1354,12 @@ TransparentReplaceVendorStringFromBufferWChar(SYSCALL_CALLBACK_CONTEXT_PARAMS *
//
// Obtain the lengths of all the strings and substring
//
ULONG tempSize = (ULONG)wcslen(NewVendorString) * sizeof(WCHAR);
ULONG TempSize = (ULONG)wcslen(NewVendorString) * sizeof(WCHAR);
ULONG MatchedStringLen = (ULONG)wcslen(HV_REGKEYS[i]) * sizeof(WCHAR);
ULONG oldLength = *((PBYTE)Buf + DataLenOffset);
ULONG OldLength = *((PBYTE)Buf + DataLenOffset);
ULONG NewStringSize = oldLength - MatchedStringLen + tempSize;
ULONG NewStringSize = OldLength - MatchedStringLen + TempSize;
//
// Check if the buffer size allows the modification, in case of expansion

View file

@ -85,7 +85,7 @@ CPU_LBR_MAP CPU_LBR_MAPS[] = {
BOOLEAN
LbrCheckAndReadArchitecturalLbrDetails()
{
ULONG A, B, C, D;
ULONG a, b, c, d;
CPUID_EAX_07 Edx07 = {0};
@ -97,9 +97,9 @@ LbrCheckAndReadArchitecturalLbrDetails()
// Check for Architectural LBR support
//
//
xcpuidex(CPUID_STRUCTURED_EXTENDED_FEATURE_FLAGS, 0x00, &A, &B, &C, &D);
xcpuidex(CPUID_STRUCTURED_EXTENDED_FEATURE_FLAGS, 0x00, &a, &b, &c, &d);
Edx07.Edx.AsUInt = D;
Edx07.Edx.AsUInt = d;
//
// CPUID.07H.00H:EDX[19] == 1 means arch LBR is supported
@ -121,7 +121,7 @@ LbrCheckAndReadArchitecturalLbrDetails()
//
// Being here means the CPU supports architectural LBR, we can read the LBR capabilities from CPUID 0x1c leaf
//
xcpuidex(CPUID_ARCH_LAST_BRANCH_RECORD_INFORMATION, 0x00, &A, &B, &C, &D);
xcpuidex(CPUID_ARCH_LAST_BRANCH_RECORD_INFORMATION, 0x00, &a, &b, &c, &d);
//
// Assign LBR leafs to structure for easier access

View file

@ -687,9 +687,9 @@ NewTemp(PSCRIPT_ENGINE_ERROR_TYPE Error)
* @brief Frees the memory allocated by Temp
*
* @param Temp the token representing the temporary variable
* @return void
* @return VOID
*/
void
VOID
FreeTemp(PSCRIPT_ENGINE_TOKEN Temp)
{
INT Id = (INT)DecimalToInt(Temp->Value);