mirror of
https://github.com/hasherezade/pe-sieve.git
synced 2026-10-11 21:49:57 +00:00
[FEATURE] Permit scanning own workingset & threads (Issue #104)
This commit is contained in:
@@ -6,8 +6,8 @@
|
||||
namespace pesieve {
|
||||
#endif
|
||||
|
||||
const char PESIEVE_VERSION[] = "0.3.4-a";
|
||||
const DWORD PESIEVE_VERSION_ID = 0x00030400; // 00 03 04 00
|
||||
const char PESIEVE_VERSION[] = "0.3.4.1";
|
||||
const DWORD PESIEVE_VERSION_ID = 0x00030401; // 00 03 04 01
|
||||
const char PESIEVE_URL[] = "https://github.com/hasherezade/pe-sieve";
|
||||
|
||||
#ifdef __cplusplus
|
||||
|
||||
@@ -211,10 +211,7 @@ ProcessScanReport* pesieve::ProcessScanner::scanRemote()
|
||||
// scan working set
|
||||
size_t regionsScanned = 0;
|
||||
try {
|
||||
//dont't scan your own working set
|
||||
if (peconv::get_process_id(this->processHandle) != GetCurrentProcessId()) {
|
||||
regionsScanned = scanWorkingSet(*pReport);
|
||||
}
|
||||
regionsScanned = scanWorkingSet(*pReport);
|
||||
} catch (std::exception &e) {
|
||||
regionsScanned = 0;
|
||||
errorsStr << e.what();
|
||||
@@ -447,11 +444,6 @@ size_t pesieve::ProcessScanner::scanThreads(ProcessScanReport& pReport) //throws
|
||||
{
|
||||
const DWORD pid = pReport.pid; //original PID, not a reflection!
|
||||
|
||||
//dont't scan your own threads - it may give wrong results:
|
||||
if (pid == GetCurrentProcessId()) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
const bool is_64bit = pesieve::util::is_process_64bit(this->processHandle);
|
||||
#ifndef _WIN64
|
||||
if (is_64bit) return 0;
|
||||
|
||||
Reference in New Issue
Block a user