1.1 --- a/sourcemm/CSmmAPI.cpp Mon May 07 18:54:30 2007 +0000
1.2 +++ b/sourcemm/CSmmAPI.cpp Fri May 11 19:14:21 2007 +0000
1.3 @@ -516,6 +516,11 @@
1.4 #define MSGCLASS2_SIGLEN 16
1.5 #define MSGCLASS2_SIG "\x56\x8B\x74\x24\x2A\x85\xF6\x7C\x2A\x3B\x35\x2A\x2A\x2A\x2A\x7D"
1.6 #define MSGCLASS2_OFFS 11
1.7 +
1.8 + /* Windows frame pointer sig */
1.9 + #define MSGCLASS3_SIGLEN 18
1.10 + #define MSGCLASS3_SIG "\x55\x8B\xEC\x51\x89\x2A\x2A\x8B\x2A\x2A\x50\x8B\x0D\x2A\x2A\x2A\x2A\xE8"
1.11 + #define MSGCLASS3_OFFS 13
1.12 #elif defined OS_LINUX
1.13 /* No frame pointer sig */
1.14 #define MSGCLASS_SIGLEN 14
1.15 @@ -586,6 +591,14 @@
1.16 /* Get address of CUserMessages::m_UserMessages */
1.17 dict = reinterpret_cast<UserMsgDict *>(*userMsgClass);
1.18 #endif
1.19 + #ifdef OS_WIN32
1.20 + } else if (vcmp(vfunc, MSGCLASS3_SIG, MSGCLASS3_SIGLEN)) {
1.21 + /* Get address of CUserMessages instance */
1.22 + char **userMsgClass = *reinterpret_cast<char ***>(vfunc + MSGCLASS3_OFFS);
1.23 +
1.24 + /* Get address of CUserMessages::m_UserMessages */
1.25 + dict = reinterpret_cast<UserMsgDict *>(*userMsgClass);
1.26 + #endif
1.27 }
1.28
1.29 if (dict)