crypto2011/IDR

assigned global byte or boolean variable probleam

csitGenny opened this issue · 1 comments

For the byte or boolean variables that has been assigned initially, the Delphi compiler will generate data "xx 8D 40 00", but the address 0x00408Dxx is valid image address usually, so all these variables IDR will generate errors global variables "^gvar_00408Dxx". When name any one variable manually, all these variables will renamed same.

Can correct it follow (May cause other problems):
Misc.cpp IsValidImageAdr function:

bool __fastcall IsValidImageAdr(DWORD Adr)
{
if (Adr >> 8 == 0x408D) return false; //Add by ZGL assigned global byte or boolean variable
if (Adr >= CodeBase && Adr < CodeBase + ImageSize)
return true;
else
return false;
}

Done. Thank you.