Hello,
Code: Select all
You should use something like readgsqword if such a macro exists. Otherwise, you get only the lower 32 bits of the pointer which makes it corrupted.PKPCR pKpCR = (PKPCR) _readgsdword(FIELD_OFFSET(KPCR, Self));