Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Export rustix::io::proc_self
  • Loading branch information
koute committed Jan 17, 2022
commit 5d0db7da90968a58be2ff442c1d745add3d5b46d
2 changes: 1 addition & 1 deletion src/io/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ pub use pipe::{pipe_with, PipeFlags};
#[cfg(not(windows))]
pub use poll::{poll, PollFd, PollFlags};
#[cfg(all(feature = "procfs", any(target_os = "android", target_os = "linux")))]
pub use procfs::proc_self_fd;
pub use procfs::{proc_self, proc_self_fd};
#[cfg(not(windows))]
pub use read_write::{pread, pwrite, read, readv, write, writev};
#[cfg(not(any(windows, target_os = "redox")))]
Expand Down
2 changes: 1 addition & 1 deletion src/io/procfs.rs
Original file line number Diff line number Diff line change
Expand Up @@ -219,7 +219,7 @@ fn proc() -> io::Result<(BorrowedFd<'static>, &'static Stat)> {
/// - [Linux]
///
/// [Linux]: https://man7.org/linux/man-pages/man5/proc.5.html
fn proc_self() -> io::Result<(BorrowedFd<'static>, &'static Stat)> {
pub fn proc_self() -> io::Result<(BorrowedFd<'static>, &'static Stat)> {
static PROC_SELF: StaticFd = StaticFd::new();

// The init function here may run multiple times; see above.
Expand Down