1.1 --- a/core-legacy/sourcehook/test/testbail2.cpp Fri Feb 27 00:19:50 2009 -0600
1.2 +++ b/core-legacy/sourcehook/test/testbail2.cpp Wed Oct 28 23:14:32 2009 -0700
1.3 @@ -5,7 +5,6 @@
1.4 #include "sourcehook_test.h"
1.5 #include "testbail.h"
1.6
1.7 -static unsigned int n_calls = 0;
1.8
1.9 int EatYams_Handler2(int a)
1.10 {
1.11 @@ -25,25 +24,13 @@
1.12 {
1.13 g_PLID = 2;
1.14
1.15 - SH_ADD_HOOK_STATICFUNC(IGaben, EatYams, g_Gabgab, EatYams_Handler2, false);
1.16 - SH_ADD_HOOK_STATICFUNC(IGaben, EatYams, g_Gabgab, EatYams_Handler3, false);
1.17 + SH_ADD_HOOK(IGaben, EatYams, g_Gabgab, SH_STATIC(EatYams_Handler2), false);
1.18 + SH_ADD_HOOK(IGaben, EatYams, g_Gabgab, SH_STATIC(EatYams_Handler3), false);
1.19
1.20 int ret = g_Gabgab->EatYams(0xDEAD);
1.21
1.22 CHECK_COND(ret == 6, "Part 2.1");
1.23
1.24 - n_calls++;
1.25 -
1.26 return true;
1.27 }
1.28 -
1.29 - void UntestBail2()
1.30 - {
1.31 - while (n_calls)
1.32 - {
1.33 - SH_REMOVE_HOOK_STATICFUNC(IGaben, EatYams, g_Gabgab, EatYams_Handler3, false);
1.34 - SH_REMOVE_HOOK_STATICFUNC(IGaben, EatYams, g_Gabgab, EatYams_Handler2, false);
1.35 - n_calls--;
1.36 - }
1.37 - }
1.38 }