MCPcopy Create free account
hub / github.com/Inori/GPCS4 / getSceFileMode

Function getSceFileMode

GPCS4/SceModules/SceLibkernel/sce_kernel_file.cpp:205–227  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

203
204
205inline sce_mode_t getSceFileMode(uint16_t oldMode)
206{
207 sce_mode_t sceMode = 0;
208 if (oldMode & _S_IREAD)
209 {
210 sceMode = SCE_KERNEL_S_IRU;
211 }
212
213 if (oldMode & _S_IWRITE)
214 {
215 sceMode = SCE_KERNEL_S_IRWU;
216 }
217
218 if (oldMode & _S_IFMT & _S_IFREG)
219 {
220 sceMode |= SCE_KERNEL_S_IFREG;
221 }
222 else if (oldMode & _S_IFMT & _S_IFDIR)
223 {
224 sceMode |= SCE_KERNEL_S_IFDIR;
225 }
226 return sceMode;
227}
228
229
230int PS4API scek_fstat(int fd, SceKernelStat *sb)

Callers 3

scek_fstatFunction · 0.85
sceKernelStatFunction · 0.85
sceKernelFstatFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected