MCPcopy Create free account
hub / github.com/emscripten-core/emscripten / __syscall_fchmod

Function __syscall_fchmod

system/lib/wasmfs/syscalls.cpp:1199–1208  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1197}
1198
1199int __syscall_fchmod(int fd, mode_t mode) {
1200 auto openFile = wasmFS.getFileTable().locked().getEntry(fd);
1201 if (!openFile) {
1202 return -EBADF;
1203 }
1204 auto lockedFile = openFile->locked().getFile()->locked();
1205 lockedFile.setMode(mode);
1206 lockedFile.updateCTime();
1207 return 0;
1208}
1209
1210int __syscall_fchownat(
1211 int dirfd, const char* path, uid_t owner, gid_t group, int flags) {

Callers 1

_wasmfs_fchmodFunction · 0.85

Calls 5

getEntryMethod · 0.80
setModeMethod · 0.80
updateCTimeMethod · 0.80
lockedMethod · 0.45
getFileMethod · 0.45

Tested by

no test coverage detected