MCPcopy Create free account
hub / github.com/RPCSX/rpcsx / getAbsolutePath

Function getAbsolutePath

rpcsx/ops.cpp:162–175  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

160}
161
162std::string getAbsolutePath(std::string path, Thread *thread) {
163 if (!path.starts_with('/')) {
164 path = "/" + std::string(thread->tproc->cwd) + "/" + path;
165 }
166
167 path = std::filesystem::path(path).lexically_normal().string();
168
169 if (!path.starts_with("/dev") &&
170 !path.starts_with("/system")) { // fixme: implement devfs mount
171 path = std::string(thread->tproc->root) + "/" + path;
172 }
173
174 return std::filesystem::path(path).lexically_normal().string();
175}
176
177orbis::SysResult mmap(orbis::Thread *thread, orbis::caddr_t addr,
178 orbis::size_t len, orbis::sint prot, orbis::sint flags,

Callers 9

openFunction · 0.85
unlinkFunction · 0.85
mkdirFunction · 0.85
rmdirFunction · 0.85
renameFunction · 0.85
dynlib_load_prxFunction · 0.85
unmountFunction · 0.85
nmountFunction · 0.85
execveFunction · 0.85

Calls 2

stringMethod · 0.80
stringFunction · 0.50

Tested by

no test coverage detected