mirror of
https://github.com/jonny-jhnson/RandomPOCs
synced 2026-06-21 13:54:51 +00:00
Fixing return values
This commit is contained in:
Binary file not shown.
Binary file not shown.
BIN
Binary file not shown.
@@ -20,7 +20,7 @@ struct TargetProcess {
|
||||
int main(int argc, const char* argv[]) {
|
||||
if (argc < 3) {
|
||||
printf("Usage: SuspendThreadDriver.exe <PID> <TID>\n");
|
||||
return 0;
|
||||
return 1;
|
||||
}
|
||||
|
||||
|
||||
@@ -31,13 +31,11 @@ int main(int argc, const char* argv[]) {
|
||||
hDevice = CreateFileW(L"\\\\.\\gmer64", GENERIC_READ | GENERIC_WRITE, 0, NULL, OPEN_EXISTING, FILE_ATTRIBUTE_NORMAL, NULL);
|
||||
if (hDevice == INVALID_HANDLE_VALUE || hDevice == NULL) {
|
||||
printf("[-] Failed to get a handle to the device object. Error: %d\n", GetLastError());
|
||||
return 0;
|
||||
return 1;
|
||||
}
|
||||
|
||||
printf("[+] Successfully got a handle to the device object.\n");
|
||||
|
||||
|
||||
|
||||
DWORD bytes;
|
||||
TargetProcess data;
|
||||
data.ProcessId = atoi(argv[1]);
|
||||
@@ -78,6 +76,5 @@ Exit:
|
||||
CloseHandle(hDevice);
|
||||
}
|
||||
|
||||
|
||||
return 0;
|
||||
}
|
||||
Reference in New Issue
Block a user