mirror of
https://github.com/themitosan/fpPS4-Temmie-s-Launcher.git
synced 2025-04-02 10:31:50 -04:00
21 lines
No EOL
516 B
C++
21 lines
No EOL
516 B
C++
#include <node.h>
|
|
#include <windows.h>
|
|
#include <TlHelp32.h>
|
|
#include <vector>
|
|
#include "memory.h"
|
|
|
|
memory::memory() {}
|
|
memory::~memory() {}
|
|
|
|
std::vector<MEMORY_BASIC_INFORMATION> memory::getRegions(HANDLE hProcess) {
|
|
std::vector<MEMORY_BASIC_INFORMATION> regions;
|
|
|
|
MEMORY_BASIC_INFORMATION region;
|
|
DWORD64 address;
|
|
|
|
for (address = 0; VirtualQueryEx(hProcess, (LPVOID)address, ®ion, sizeof(region)) == sizeof(region); address += region.RegionSize) {
|
|
regions.push_back(region);
|
|
}
|
|
|
|
return regions;
|
|
} |