1
0
mirror of https://github.com/alliedmodders/metamod-source.git synced 2024-11-28 10:24:20 +01:00

Shut msvc

This commit is contained in:
Kenzzer 2024-02-04 02:31:35 +01:00 committed by Nicholas Hastings
parent f950db71dd
commit 37408219ba
2 changed files with 8 additions and 2 deletions

View File

@ -907,7 +907,10 @@ SourceHook::CallClass<T> *SH_GET_CALLCLASS(T *p)
/* patch mfp */ \
*reinterpret_cast<void**>(&mfp) = *reinterpret_cast<void**>(vfnptr); \
if (sizeof(mfp) == 2*sizeof(void*)) /* gcc */ \
*(reinterpret_cast<void**>(&mfp) + 1) = 0; \
{ \
void** pleaseShutUpMsvc = reinterpret_cast<void**>(&mfp); \
pleaseShutUpMsvc[1] = 0; \
} \
return SH_MFHCls(hookname)::CallEC(reinterpret_cast< ::SourceHook::EmptyClass* >(ptr), mfp, vfnptr, SH_GLOB_SHPTR); \
} \
void __SourceHook_FHM_Reconfigure##hookname(int p_vtblindex, int p_vtbloffs, int p_thisptroffs) \

View File

@ -907,7 +907,10 @@ SourceHook::CallClass<T> *SH_GET_CALLCLASS(T *p)
/* patch mfp */ \
*reinterpret_cast<void**>(&mfp) = *reinterpret_cast<void**>(vfnptr); \
if (sizeof(mfp) == 2*sizeof(void*)) /* gcc */ \
*(reinterpret_cast<void**>(&mfp) + 1) = 0; \
{ \
void** pleaseShutUpMsvc = reinterpret_cast<void**>(&mfp); \
pleaseShutUpMsvc[1] = 0; \
} \
return SH_MFHCls(hookname)::CallEC(reinterpret_cast< ::SourceHook::EmptyClass* >(ptr), mfp, vfnptr, SH_GLOB_SHPTR); \
} \
void __SourceHook_FHM_Reconfigure##hookname(int p_vtblindex, int p_vtbloffs, int p_thisptroffs) \