Skip to content

Commit 6aa3221

Browse files
authored
Fix some typos (#987)
1 parent 3e3cf73 commit 6aa3221

File tree

7 files changed

+8
-8
lines changed

7 files changed

+8
-8
lines changed

src/backend/libc/event/epoll.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -187,7 +187,7 @@ pub fn add(
187187
// SAFETY: We're calling `epoll_ctl` via FFI and we know how it
188188
// behaves. We use our own `Event` struct instead of libc's because
189189
// ours preserves pointer provenance instead of just using a `u64`,
190-
// and we have tests elsehwere for layout equivalence.
190+
// and we have tests elsewhere for layout equivalence.
191191
unsafe {
192192
let raw_fd = source.as_fd().as_raw_fd();
193193
ret(c::epoll_ctl(
@@ -219,7 +219,7 @@ pub fn modify(
219219
// SAFETY: We're calling `epoll_ctl` via FFI and we know how it
220220
// behaves. We use our own `Event` struct instead of libc's because
221221
// ours preserves pointer provenance instead of just using a `u64`,
222-
// and we have tests elsehwere for layout equivalence.
222+
// and we have tests elsewhere for layout equivalence.
223223
unsafe {
224224
ret(c::epoll_ctl(
225225
epoll.as_fd().as_raw_fd(),

src/backend/libc/fs/dir.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -131,7 +131,7 @@ impl Dir {
131131

132132
/// `readdir(self)`, where `None` means the end of the directory.
133133
pub fn read(&mut self) -> Option<io::Result<DirEntry>> {
134-
// If we've seen errors, don't continue to try to read anyting further.
134+
// If we've seen errors, don't continue to try to read anything further.
135135
if self.any_errors {
136136
return None;
137137
}

src/backend/linux_raw/fs/dir.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,7 @@ impl Dir {
8181

8282
/// `readdir(self)`, where `None` means the end of the directory.
8383
pub fn read(&mut self) -> Option<io::Result<DirEntry>> {
84-
// If we've seen errors, don't continue to try to read anyting further.
84+
// If we've seen errors, don't continue to try to read anything further.
8585
if self.any_errors {
8686
return None;
8787
}

src/fs/abs.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -182,7 +182,7 @@ pub fn rmdir<P: path::Arg>(path: P) -> io::Result<()> {
182182
/// POSIX leaves it implementation-defined whether `link` follows a symlink in
183183
/// `old_path`, or creates a new link to the symbolic link itself. On platforms
184184
/// which have it, [`linkat`] avoids this problem since it has an [`AtFlags`]
185-
/// paramter and the [`AtFlags::SYMLINK_FOLLOW`] flag determines whether
185+
/// parameter and the [`AtFlags::SYMLINK_FOLLOW`] flag determines whether
186186
/// symlinks should be followed.
187187
///
188188
/// # References

src/fs/at.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -139,7 +139,7 @@ fn _readlinkat(dirfd: BorrowedFd<'_>, path: &CStr, mut buffer: Vec<u8>) -> io::R
139139
/// significantly trickier to use; most users should use plain [`readlinkat`].
140140
///
141141
/// This version writes bytes into the buffer and returns two slices, one
142-
/// containing the written bytes, and one containint the remaining
142+
/// containing the written bytes, and one containing the remaining
143143
/// uninitialized space. If the number of written bytes is equal to the length
144144
/// of the buffer, it means the buffer wasn't big enough to hold the full
145145
/// string, and callers should try again with a bigger buffer.

src/process/pidfd_getfd.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ bitflags::bitflags! {
4040
/// returned from `pidfd_getfd`.
4141
///
4242
/// When `pidfd_getfd` is used to debug the target, or the target is not a Rust
43-
/// aplication, or `pidfd_getfd` is used in any other way, then extra care
43+
/// application, or `pidfd_getfd` is used in any other way, then extra care
4444
/// should be taken to avoid unexpected behaviour or crashes.
4545
///
4646
/// For further details, see the references above.

tests/fs/file.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -174,7 +174,7 @@ fn test_setfl_append() {
174174
.unwrap();
175175
assert_eq!(rustix::io::write(&file, b"abcdefghijklmnop"), Ok(16));
176176

177-
// Overwite the first few bytes.
177+
// Overwrite the first few bytes.
178178
let file =
179179
rustix::fs::open(tmp.path().join("test.file"), OFlags::WRONLY, Mode::empty()).unwrap();
180180
assert_eq!(rustix::io::write(&file, b"uvw"), Ok(3));

0 commit comments

Comments
 (0)