diff options
author | bors[bot] <26634292+bors[bot]@users.noreply.github.com> | 2022-02-06 23:31:42 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-02-06 23:31:42 +0000 |
commit | 2038ce6b99c7287c1d80c5df2fcc9cf2de131a32 (patch) | |
tree | d2c37caf5474bf351914027ec2ada5a45e7458ee /src/sys/inotify.rs | |
parent | 0bd56d96e3b2a4b19ef539e6bd01f3441ecfed1d (diff) | |
parent | 7baf6d12c88bfba20b77c68353826702c7248fcd (diff) | |
download | nix-2038ce6b99c7287c1d80c5df2fcc9cf2de131a32.zip |
Merge #1653
1653: Document inotify, mman, personality, reboot, timerfd r=asomers a=rtzoeller
Document the `inotify`, `mman`, `personality`, `reboot`, and `timerfd` modules.
Co-authored-by: Ryan Zoeller <rtzoeller@rtzoeller.com>
Diffstat (limited to 'src/sys/inotify.rs')
-rw-r--r-- | src/sys/inotify.rs | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/src/sys/inotify.rs b/src/sys/inotify.rs index d6697a4a..b19dbe12 100644 --- a/src/sys/inotify.rs +++ b/src/sys/inotify.rs @@ -41,31 +41,53 @@ use cfg_if::cfg_if; libc_bitflags! { /// Configuration options for [`inotify_add_watch`](fn.inotify_add_watch.html). pub struct AddWatchFlags: u32 { + /// File was accessed. IN_ACCESS; + /// File was modified. IN_MODIFY; + /// Metadata changed. IN_ATTRIB; + /// Writable file was closed. IN_CLOSE_WRITE; + /// Nonwritable file was closed. IN_CLOSE_NOWRITE; + /// File was opened. IN_OPEN; + /// File was moved from X. IN_MOVED_FROM; + /// File was moved to Y. IN_MOVED_TO; + /// Subfile was created. IN_CREATE; + /// Subfile was deleted. IN_DELETE; + /// Self was deleted. IN_DELETE_SELF; + /// Self was moved. IN_MOVE_SELF; + /// Backing filesystem was unmounted. IN_UNMOUNT; + /// Event queue overflowed. IN_Q_OVERFLOW; + /// File was ignored. IN_IGNORED; + /// Combination of `IN_CLOSE_WRITE` and `IN_CLOSE_NOWRITE`. IN_CLOSE; + /// Combination of `IN_MOVED_FROM` and `IN_MOVED_TO`. IN_MOVE; + /// Only watch the path if it is a directory. IN_ONLYDIR; + /// Don't follow symlinks. IN_DONT_FOLLOW; + /// Event occurred against directory. IN_ISDIR; + /// Only send event once. IN_ONESHOT; + /// All of the events. IN_ALL_EVENTS; } } @@ -73,7 +95,9 @@ libc_bitflags! { libc_bitflags! { /// Configuration options for [`inotify_init1`](fn.inotify_init1.html). pub struct InitFlags: c_int { + /// Set the `FD_CLOEXEC` flag on the file descriptor. IN_CLOEXEC; + /// Set the `O_NONBLOCK` flag on the open file description referred to by the new file descriptor. IN_NONBLOCK; } } |