Skip to content

Instantly share code, notes, and snippets.

@aixxe
Last active February 24, 2022 11:03
  • Star 0 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
Star You must be signed in to star a gist
Save aixxe/2288339f0be633300a8da85003de75bf to your computer and use it in GitHub Desktop.
Helper function to resolve RIP relative addresses.
inline uintptr_t GetAbsoluteAddress(uintptr_t instruction_ptr, int offset, int size) {
return instruction_ptr + *reinterpret_cast<int32_t*>(instruction_ptr + offset) + size;
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment