You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

29 lines
555B

  1. #include <Windows.h>
  2. #include <cstdint>
  3. #include <iostream>
  4. #include "../test_cases/test_cases.h"
  5. #include "abstracthook.h"
  6. #include "mhook.h"
  7. #pragma comment(lib, "..\\x64\\debug\\test_cases.lib")
  8. extern AbstractHookEngine* g_mhook;
  9. int main(int argc, char** argv) {
  10. AbstractHookEngine* engines[] = {
  11. g_mhook,
  12. };
  13. for(auto&& x : engines) {
  14. if (!x->hook_all()) {
  15. std::cerr << x->name() << " can't hook\n";
  16. x->unhook_all();
  17. continue;
  18. }
  19. SelfTest();
  20. std::cout << x->name() << ':' << x->all_hooked() << '\n';
  21. x->unhook_all();
  22. }
  23. }