clean up on close

This commit is contained in:
Akash Mozumdar 2018-08-22 11:51:28 -04:00
parent e35e26c2eb
commit af1512b7bf

View File

@ -39,7 +39,9 @@ namespace Host
{ {
// Artikash 7/25/2018: This is only called when NextHooker is closed, at which point Windows should free everything itself...right? // Artikash 7/25/2018: This is only called when NextHooker is closed, at which point Windows should free everything itself...right?
HOST_LOCK; HOST_LOCK;
OnRemove = [](TextThread* textThread) { delete textThread; };
for (auto i : processRecordsByIds) UnregisterProcess(i.first); for (auto i : processRecordsByIds) UnregisterProcess(i.first);
delete textThreadsByParams[{ 0, -1UL, -1UL, -1UL }];
} }
DLLEXPORT bool InjectProcess(DWORD processId, DWORD timeout) DLLEXPORT bool InjectProcess(DWORD processId, DWORD timeout)