MCPcopy Create free account
hub / github.com/ModOrganizer2/modorganizer / canAccess

Method canAccess

src/envmodule.cpp:398–410  ·  view source on GitHub ↗

whether this process can be accessed; fails if the current process doesn't have the proper permissions

Source from the content-addressed store, hash-verified

396// have the proper permissions
397//
398bool Process::canAccess() const
399{
400 HandlePtr h(OpenProcess(PROCESS_QUERY_INFORMATION | PROCESS_VM_READ, FALSE, m_pid));
401
402 if (!h) {
403 const auto e = GetLastError();
404 if (e == ERROR_ACCESS_DENIED) {
405 return false;
406 }
407 }
408
409 return true;
410}
411
412void Process::addChild(Process p)
413{

Callers 1

getSteamStatusFunction · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected