Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit 910e23b

Browse files
Rollup merge of rust-lang#123084 - a1phyr:unixstream_read_buf, r=workingjubilee
`UnixStream`: override `read_buf` Split from rust-lang#122441 r? ``@workingjubilee``
2 parents d589021 + bff13e9 commit 910e23b

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

‎library/std/src/os/unix/net/stream.rs‎

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -580,6 +580,10 @@ impl io::Read for UnixStream {
580580
io::Read::read(&mut &*self, buf)
581581
}
582582

583+
fn read_buf(&mut self, buf: io::BorrowedCursor<'_>) -> io::Result<()> {
584+
io::Read::read_buf(&mut &*self, buf)
585+
}
586+
583587
fn read_vectored(&mut self, bufs: &mut [IoSliceMut<'_>]) -> io::Result<usize> {
584588
io::Read::read_vectored(&mut &*self, bufs)
585589
}
@@ -596,6 +600,10 @@ impl<'a> io::Read for &'a UnixStream {
596600
self.0.read(buf)
597601
}
598602

603+
fn read_buf(&mut self, buf: io::BorrowedCursor<'_>) -> io::Result<()> {
604+
self.0.read_buf(buf)
605+
}
606+
599607
fn read_vectored(&mut self, bufs: &mut [IoSliceMut<'_>]) -> io::Result<usize> {
600608
self.0.read_vectored(bufs)
601609
}

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /