|
- #include <Windows.h>
- #include <cstdint>
- #include <iostream>
- #include "../test_cases/test_cases.h"
-
- #include "abstracthook.h"
- #include "mhook.h"
-
- #pragma comment(lib, "..\\x64\\debug\\test_cases.lib")
-
- extern AbstractHookEngine* g_mhook,
- *g_PolyHook;
-
- int main(int argc, char** argv) {
- AbstractHookEngine* engines[] = {
- g_mhook,
- g_PolyHook
- };
-
- for(auto&& x : engines) {
- if (!x->hook_all()) {
- std::cerr << x->name() << " can't hook\n";
- x->unhook_all();
- continue;
- }
-
- SelfTest();
- std::cout << x->name() << ':' << x->all_hooked() << '\n';
- x->unhook_all();
- }
- }
|