From 0f44a0c6f8ca3b6859784fa15d413b0ba53edba9 Mon Sep 17 00:00:00 2001 From: Akash Mozumdar Date: Sun, 9 Jun 2019 08:10:44 -0400 Subject: [PATCH] start injeccted --- testbed/main.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/testbed/main.cpp b/testbed/main.cpp index 1c99f21..dabe57e 100644 --- a/testbed/main.cpp +++ b/testbed/main.cpp @@ -1,4 +1,5 @@ #include "common.h" +#include "defs.h" #include "resource.h" wchar_t buffer[1000] = {}; @@ -6,6 +7,8 @@ std::array vars = {}; int WINAPI WinMain(HINSTANCE hInstance, HINSTANCE, LPSTR, int) { + LoadLibraryW(ITH_DLL); + ShowWindow(CreateDialogParamW(hInstance, MAKEINTRESOURCEW(IDD_DIALOG1), NULL, [](HWND hWnd, UINT uMsg, WPARAM wParam, LPARAM lParam) -> INT_PTR { switch (uMsg) @@ -26,7 +29,7 @@ int WINAPI WinMain(HINSTANCE hInstance, HINSTANCE, LPSTR, int) { GetWindowTextW((HWND)lParam, buffer, std::size(buffer)); try { vars.at(LOWORD(wParam) - IDC_EDIT1) = std::stoi(buffer); } - catch (std::invalid_argument&) {} + catch (...) {} } } break;