Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save xorhex/b5a287790d52e744f06b4f6d7e666ccb to your computer and use it in GitHub Desktop.
Save xorhex/b5a287790d52e744f06b4f6d7e666ccb to your computer and use it in GitHub Desktop.
Code Snippet 3 - Pin Tool instrumentation function
VOID Image(IMG img, VOID *v)
{
RTN sysDefUILangRtn = RTN_FindByName(img, GETSYSTEMDEFAULTUILANGUAGE);
if (RTN_Valid(sysDefUILangRtn)) {
RTN_Open(sysDefUILangRtn);
if (newLangCode > 0)
RTN_Replace(sysDefUILangRtn, (AFUNPTR)SetSystemDefaultUILanguage);
RTN_Close(sysDefUILangRtn);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment