Home
last modified time | relevance | path

Searched refs:procfd (Results 1 – 2 of 2) sorted by relevance

/Linux-v5.4/samples/pidfd/
Dpidfd-metadata.c54 int procfd, ret; in pidfd_metadata_fd() local
58 procfd = open(path, O_DIRECTORY | O_RDONLY | O_CLOEXEC); in pidfd_metadata_fd()
59 if (procfd < 0) { in pidfd_metadata_fd()
76 close(procfd); in pidfd_metadata_fd()
77 procfd = -1; in pidfd_metadata_fd()
81 return procfd; in pidfd_metadata_fd()
89 int procfd, statusfd; in main() local
100 procfd = pidfd_metadata_fd(pid, pidfd); in main()
102 if (procfd < 0) in main()
105 statusfd = openat(procfd, "status", O_RDONLY | O_CLOEXEC); in main()
[all …]
/Linux-v5.4/tools/testing/selftests/filesystems/
Ddevpts_pts.c85 char procfd[4096]; in resolve_procfd_symlink() local
87 ret = snprintf(procfd, 4096, "/proc/self/fd/%d", fd); in resolve_procfd_symlink()
91 ret = readlink(procfd, buf, buflen); in resolve_procfd_symlink()